Evening everyone...
First, this is a homework assignment and I am not looking for the direct answer (notice no code...), but instead I need direction to help figure this out. I am new to this and do not plan on continuing after this class. Not my forte...
I have to encrypt and decrypt a char pointer. I have passed the pointer to the encrypt function (debug code reveals - output statement). I need to increase the value by 1 in the encrypt function and then decrease by one in the decrypt function.
To do this I need to convert the characters to ASCII, then add 1 and then reconvert back to characters, right? Can someone provide guidance on how to do this? Then to do the decrypt, I pass the returned value as a pointer from the encrypt function to the decrypt function and do that conversion, right?
I will post code if need be...but don't it is necessary at this point.
First, this is a homework assignment and I am not looking for the direct answer (notice no code...), but instead I need direction to help figure this out. I am new to this and do not plan on continuing after this class. Not my forte...
I have to encrypt and decrypt a char pointer. I have passed the pointer to the encrypt function (debug code reveals - output statement). I need to increase the value by 1 in the encrypt function and then decrease by one in the decrypt function.
To do this I need to convert the characters to ASCII, then add 1 and then reconvert back to characters, right? Can someone provide guidance on how to do this? Then to do the decrypt, I pass the returned value as a pointer from the encrypt function to the decrypt function and do that conversion, right?
I will post code if need be...but don't it is necessary at this point.
Comment