Caesar: A MATLAB function for encryption and decryption of strings.
Caesar Encryption and Decryption of strings in MATLAB Description This MATLAB function named "caesar", I wrote for an assignment of an online course of Vanderbilt University via Coursera. The function takes two inputs, namely feed and shift. and gives output as coded feed: a string to be encrypted or an already encrypted string to be decrypted Shift: a value to encrypt or decrypt the string Remember that when we decrypt the string, we place an opposite sign before the shift ( if the shift is 45 then make it -45 or vice versa) Algorithm Feed is converted to double ( data type) a copy of the feed is created divide the shift by 95 and take the remainder a for loop is created to the length of the feed if the sum of character and shift is greater than 126 then the value above 126 is added to 31 and is saved as the new character in place of the original one. if the sum of character and shift is less than 32 then character, shift, and 127 are added together and 32 is subtracted ...