What is the reason one of my vigenere.c input files gives different results when checked with check50 and separately for the cases with BaZ and BAZ keys? My check50 results and my individual test cases with Baz and BAZ keys are given below
jharvard@appliance (~/Dropbox/pset2): check50 2014.fall.pset2.vigenere vigenere.c :) vigenere.c exists :) vigenere.c compiles :) encrypts "a" as "a" using "a" as keyword :) encrypts "world, say hello!" as "xoqmd, rby gflkp!" using "baz" as keyword :( encrypts "BaRFoo" as "CaQGon" using "BaZ" as keyword \ expected output, but not "CaQGoh\n" :) encrypts "BARFOO" as "CAQGON" using "BAZ" as keyword :( handles lack of argv \ expected an exit code of 1, not a prompt for input :( handles argc > 2 \ expected an exit code of 1, not a prompt for input :( rejects "Hax0r2" as keyword \ expected output, not a prompt for input https://sandbox.cs50.net/checks/2f7e9491d3b6431e9e712e64f60b9a5b
jharvard@appliance (~/Dropbox/pset2): ./vigenere BaZ BaRFoo CaQGoh
jharvard@appliance (~/Dropbox/pset2): ./vigenere BAZ BAZFOO CAYGON
While trying to use Kareem's algorithm I tried to use a for loop to set all key values in the range (0-25 ). But I am getting an error message saying that the loop results are not being used. How can one reduce all key values to the range (0-25) without having another loop?