Write Function Named Printtwice Takes String Prints Twice Call Least Two Different Strings Q37080796

  1. Write a function named print_twice that takes a string andprints it out twice. Call it with at least two different strings ofyour choice.

  2. Write a function named print_three_times that takes a string andprints it out three times. Ask the user for a string input, andcall print_three_times with the user’s string as the argument.

Please Use PYTHON!!!


Solution


#Code1.pydef print_twice(s): print(s) print(s)#Testingprint_twice(“Test”)print_twice(“qwerty”)

===============================

#Code2.pydef print_three_times(s): print(s) print(s) print(s)#Testingprint_three_times(“Test”)print_three_times(“qwerty”)

Leave a Comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.