Question: Write a function that takes four parameters: repeat: a positive integer symbol: a single character ( possibly empty ) word: a string ( possibly empty

Write a function that takes four parameters: repeat: a positive integer symbol: a single character (possibly empty) word: a string (possibly empty) repeat_again: a positive integer Your function should return a string, where a symbol is repeated repeat number of times, then word is attached, the symbol is repeated repeat_again number of times and everything is in the reverse order. def second_pattern(repeat, symbol, word, repeat_again): """>>> second_pattern(3,'*', 'pattern', 2)'**nrettap***'>>> second_pattern(6,'$', 'journey', 3)'$$$yenruoj$$$$$$'>>> second_pattern(3,'','',2)''"""

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!