Answer:
Following are the program in the python language
def get_ends(s1): #define function
return(s1[0].upper(), s1[-1].upper()) #returning the first and last letter of the string s1
#function calling
f1,l1 = get_ends("python")
print(f1,l1) #print the first and last letter of the string.
Output:
P N
Step-by-step explanation:
In this program we create a function get_ends() which returning the first and last letter of the string s1 .
After returning the string will store in f1,l1 respectively .
Finally we print the first and last letter of the string .