Write program in C++ please :) Write a function that will prompt the user for two strings. It will then encrypt the fir

Business, Finance, Economics, Accounting, Operations Management, Computer Science, Electrical Engineering, Mechanical Engineering, Civil Engineering, Chemical Engineering, Algebra, Precalculus, Statistics and Probabilty, Advanced Math, Physics, Chemistry, Biology, Nursing, Psychology, Certifications, Tests, Prep, and more.
Post Reply
answerhappygod
Site Admin
Posts: 899603
Joined: Mon Aug 02, 2021 8:13 am

Write program in C++ please :) Write a function that will prompt the user for two strings. It will then encrypt the fir

Post by answerhappygod »

Write program in C++ please :)Write a function that will prompt the user for two strings. It will then encrypt the first string with the secondstring using the Vigenere ciphere. The first string is the plaintext and your function should ignore all non-alphabetic characters (or your code can remove them from the string). All uppercase letters should be treated aslowercase letters (or you can convert the string to all lowercase letters). The second string is the key and itshould be able to be from 1 character long to even longer than the plaintext string itself.Then write a function that, given two strings, decrypts the first string using the second string. Same conditionsshould apply as before.Once these functions are completed, have your main body prompt the user for a string to encode, then a keystring, then perform the encryption of the plaintext and output the ciphertext. Then decrypt it and show theresulting plaintext.
Join a community of subject matter experts. Register for FREE to view solutions, replies, and use search function. Request answer by replying!
Post Reply