I'm trying to iterate repeatedly over key (a word) which the user inputs on the command line. This keyword is used to encipher a word which the user inputs when prompted by the word 'plaintext'. I have to cycle over the letters in the key, while enciphering the plaintext word. I'm getting the errors:
incompatible pointer types passing 'char **' to parameter of type 'const char *'; dereference with * [-Wincompatible-pointer-types] /usr/include/string.h:82:28: note: passing argument to parameter '__s' here size_t strlen(const char *__s); I'm confused as to how to iterate through integers, which appears to be necessary where ASCII is concerned where the input key are not integers. At least I think that's the problem. Some help would be appreciated.
int main(int argc, char* argv[]) { if (argc<2) //re key entered on command line { printf("Please enter your word key"); return 1; } int key = atoi(argv[1]); if(argc>=2) { printf("plaintext:"); char* word = GetString(); printf("ciphertext:"); do { //starts loop to iterate through the letters in the key for(int l=0; l<strlen(argv); l++)//iterate over key letters { int num=l; for(int i=0; i<strlen(word); i++) //iterates through word entered by user as plaintext {