Write a Python program string_functions.py that defines several functions. Each function re-implements Python's built-in string methods
1 answer:
Answer:
def length( mystring):
count = 0
for i in mystring:
count += 1
return count
def reversed( mystring):
strlist = []
for i in range(length(mystring)):
strlist.append(mystring[(length(mystring) - 1) - i])
txt = "".join(strlist)
return txt
string = 'Yolanda'
print(reversed(string))
Explanation:
The python module defines two functions 'reversed' and 'length'. The length function counts the number of characters in a string variable while the reversed function reverses the string variable value.
You might be interested in
A sub routine could refer to a method, procedure or function of sum sort
The default is normal view orientation.
Answer:
reply
Explanation:
hit the reply button to do that
answer: C
explanation: because it's the biggest of the given platforms
Answer:
The comparison is done based on their basic, principle, plaintext, key size, rounds, rounds name, security and speed. See the attached document.
Explanation:
The the attachment