subject
Computers and Technology, 21.03.2020 07:54 ava5015

**Please it is necessary to use the functions and the names given. It is also important to use string and getline.**

Implement two decryption functions corresponding to the above ciphers. When decrypting ciphertext, ensure that the produced decrypted string is equal to the original plaintext:

decryptCaesar(ciphertext, rshift) == plaintext
decryptVigenere(ciphertext, keyword) == plaintext
Write a program decryption. cpp that uses the above functions to demonstrate encryption and decryption for both ciphers.

It should first ask the user to input plaintext, then ask for a right shift for the Caesar cipher and report the ciphertext and its subsequent decryption. After that, it should do the same for the Vigenere cipher.

Example:

$ ./decryption

Enter plaintext: Hello, World!

= Caesar =
Enter shift : 10
Ciphertext : Rovvy, Gybvn!
Decrypted : Hello, World!

= Vigenere =
Enter keyword : cake
Ciphertext : Jevpq, Wyvnd!
Decrypted : Hello, World!

(When reporting decrypted strings, they should be the result of applying decryption functions to the ciphertext, not the original plaintext variable.)

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 10:20
Print "usernum1 is negative." if usernum1 is less than 0. end with newline. convert usernum2 to 0 if usernum2 is greater than 10. otherwise, print "usernum2 is less than or equal to 10.". end with newline
Answers: 3
question
Computers and Technology, 22.06.2019 13:00
We as humans write math expression in infix notation, e.g. 5 + 2 (the operators are written in-between the operands). in a computer’s language, however, it is preferred to have the operators on the right side of the operands, i.e. 5 2 +. for more complex expressions that include parenthesis and multiple operators, a compiler has to convert the expression into postfix first and then evaluate the resulting postfix.write a program that takes an “infix” expression as input, uses stacks to convert it into postfix expression, and finally evaluates it. it must support the following operations: + - / * ^ % (example infix expression: (7 - 3) / (2 + 2)postfix expression: 7 3 - 2 2 + /result: 1guidelines: 1. you will need to use stacks in three placesa. one for the parenthesis check [char stack]b. one during infix to postfix [char stack]c. one during evaluation [int stack]for a and b above, you can use same array and same push, pop method as both ofthem are char. but for evaluation you have int stack and you might consider to createanother push pop method to handle it. maybe push_int, pop_int, etc. or find otherstrategy to utilize existing push pop method2. you can create a function for obtaining operator priority. that function should take anoperator as input and return its priority as an integer. this function will you a lot andreduce repeated code3. during evaluation you will need to convert char into integer. example for single digit: char c = '5'; int x = c - '0';
Answers: 2
question
Computers and Technology, 23.06.2019 00:30
Which one of the following is the most accurate definition of technology? a electronic tools that improve functionality b electronic tools that provide entertainment or practical value c any type of tool that serves a practical function d any type of tool that enhances communication
Answers: 1
question
Computers and Technology, 23.06.2019 15:00
What is the total resistance in a circuit that contains three 60 ohm resistors connected in a series? a. 20 ohms b. 120 ohms c. 60 ohms d. 180 ohms
Answers: 2
You know the right answer?
**Please it is necessary to use the functions and the names given. It is also important to use strin...
Questions
Questions on the website: 13722367