Reverse a string in python

266 viewsPython

Reverse a string in python

Have the function FirstReverse(str) take the str parameter being passed and return the string in reversed order. For example: if the input string is “Hello World and Coders” then your program should return the string sredoC dna dlroW olleH.

Farjanul Answered question July 22, 2022
0

def FirstReverse(strParam):
  return strParam[::-1]
 # keep this function call here 
print(FirstReverse(input()))

Farjanul Answered question July 22, 2022
0
You are viewing 1 out of 1 answers, click here to view all answers.