Design a nested structure by considering the production of at least 5 fruits in Pakistan’s provinces. Consider suitable attributes of fruits, names of use defined constructs must be user friendly. Use proper string messages to make your program readable.
1
Expert's answer
2021-11-29T00:00:09-0500
l = []
i = 0
while True:
s = input("Input the fruit names: ")
if len(s) < 5:
print("Name is not illigable")
else:
l.append(s)
i += 1
if i == 5: break
print(*l)
Comments
Leave a comment