I've finally fixed the other problems from check50, including the Hax0r2 check but my code appears to be terminating before it starts enciphering. For each of the enciphering checks on check50 I'm getting the error:
\ expected output, but not "Please enter your single word key",
(which is, of course, the return 1: prompt.) Here is a short segment of the code. Obviously only part of the cipher code is here to avoid spoilers. I hope someone can advise me.
int main(int argc, char* argv[])
{
if ((argc<2) || (argc>2) || (!isalpha(strlen(argv[1]))))
{
printf("Please enter your single word key");
return 1;
}
else
{
printf("plaintext:");
char* word = GetString();
char* key = (argv[1]);
printf("ciphertext:");
int keylen = strlen(key);
int wordlen = strlen(word);
for(int wordpos = 0, keypos = 0; wordpos<wordlen; wordpos++)
{
if(isupper(wordpos))
{
int cipher = (wordpos + keypos -65) % 26 + 65;
printf("%c", cipher);