Question: Code Challenge: Assume that a function encrypt ( ) has already been defined for you. encrypt ( ) takes in a str as a parameter,

Code Challenge: Assume that a function encrypt() has already been defined for you. encrypt() takes in a str as a parameter, performs some special (black-box) calculations using the string, and returns an int value, which we will call the encrypted value of the input string.
Write a function encrypted_print() that takes in a str, computes its encrypted value, and prints the str "ENCRYPTED" encrypted value number of times.
Example: If we call encrypted_print("xyz") and encrypt("xyz") is 2, your program should output:
ENCRYPTED
ENCRYPTED
Sample Input:
xyz
Sample Output:
ENCRYPTED
ENCRYPTED
Write a program, test using stdin -> stdout

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!