Answered step by step
Verified Expert Solution
Question
1 Approved Answer
4.1 Caesar's Cipher (3-pt) Caesar's cipher is a very simple encrypting scheme where each letter is shifted down by a fixed number from its position
4.1 Caesar's Cipher (3-pt) Caesar's cipher is a very simple encrypting scheme where each letter is shifted down by a fixed number from its position in the alphabet. For example, if the given character set is the English alphabet in upper case and the shift number is 3, then each letter in "ABCDEFGHIJKLMNOPQRSTUVWXYZ" from the plain text will be replaced by "DEFGHIJKLMNOPQRSTUVWXYZABC", respectively, in the cipher text. Now in this exercise, your character set (alphabet) is the concatenation of all uppercase and lowercase letters: const string alphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz"; You're given two cipher text strings as the following- "UIFZBOLTBSFBMTP10PXobTuIFCSPOYCPNCFST" "dBFTBSdJQIFSEYFSDJTFXJUIdqMVTqMVT" You're also given the condition that the corresponding plain text of the first cipher text of the above contains the string "Yanks". Write a C++ program to figure out the shift number then decipher and print out the plain text for both, from your program. 4.2 A library record class with derived classes for books and CDs (5-pt) The ItemRecord class maintains books and other media records for a library. Its attributes include the title(string), price(double), rating(char: 'A'-'D' in descending popularity). The operations include: 1. a constructor that takes default values ("placeholder", 0.99, 'D'), and checks for invariants (negative price, invalid rating letters, etc) 2. individual getters that return the item's title, price, and rating 3. overloaded
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started