Write a function that accepts a password string “WasillaDogSleddingRulz” and per
ID: 3631400 • Letter: W
Question
Write a function that accepts a password string “WasillaDogSleddingRulz” and perform a (very) weak encryption: For each character in the string, change the character to some other garbage character in the ASCII table by performing two consecutive, reversible math operations on it. Be sure the values do not go below 0 or above 127.Write a second function that accepts your 'encrypted' string and reverses the encryption. This function will output another character array such that all the characters are the same as the original string. Include in your main method iterators that output the characters at each index of the three
strings for comparison.
Explanation / Answer
#include #include using namespace std; string encrypt(string str1) { string str2; int len=str1.size(); coutRelated Questions
Hire Me For All Your Tutoring Needs
Integrity-first tutoring: clear explanations, guidance, and feedback.
Drop an Email at
drjack9650@gmail.com
drjack9650@gmail.com
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.