def new_string(str):
if len(str) >= 2 and str[:2] == "Is":
return str
return "Is" + strprint(new_string("Array"))
print(new_string("IsEmpty"))
Output:
IsArray
IsEmpty
def new_string(str):
if len(str) >= 2 and str[:2] == "Is":
return str
return "Is" + strprint(new_string("Array"))
print(new_string("IsEmpty"))
Output:
IsArray
IsEmpty
Python program to find maximum in arr[] of size n
Python code to find sum of elements in given array
Python program to find the largest of three numbers
write() and read() in file handling in python
Python program that accepts an integer (n) and computes the value of n+nn+nnn
Python program to print formatted string
What is Break statement in python
Increment and decrement operator in python
Python program to find the roots of Quadratic equation
Python Program to generate a random number between 0 and 9
Python program to accept a filename from the user and print the extension of that
Python program which takes radius from user and print area