Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

gestion 4 Write a function call encrypt that has a string with all lower characters s and an integer r. It will change the string

image text in transcribed
gestion 4 Write a function call encrypt that has a string with all lower characters s and an integer r. It will change the string by shifting each character by r letters. ('z' will loop back to 'a). You need to name your parameters s and r. You may assume all the characters in your string s are lower case letters. Excessively long solutions may lose points. A program that uses the function encrypt follows. int main({ string s1 = "college", s2 = "zoo", $3 ="abcde"; encrypt(s1,2); cout d-> e, o -> p->q, 1->m-> n, etc. encrypt($2,4); cout a ->b->c->do>p->q>r->s encrypt(:3,27); cout

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Students also viewed these Programming questions