Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- }else{
- if((int)msg[i] + actualShift > 122){ // check if it needs to wrap
- int wrapShift = actualShift - (122 -(int)msg[i]);
- msg[i] = (char)(96 + wrapShift);
- }else
- msg[i] = (char)((int)msg[i] + actualShift);
- }
Add Comment
Please, Sign In to add comment