Answer:
<em>This program is written using Python Programming language,</em>
<em>The program doesn't make use of comments (See explanation section for line by line explanation)</em>
<em>Program starts here</em>
print("Enter elements into the list. Enter 0 to stop")
newlist = []
b = float(input("User Input: "))
while not b==0:
newlist.append(b)
b = float(input("User Input: "))
newlist.sort()
print("Largest element is:", newlist[-1])
Explanation:
This line gives the user instruction on how to populate the list and how to stop
print("Enter elements into the list. Enter 0 to stop")
This line creates an empty list
newlist = []
This line enables the user to input numbers; float datatype was used to accommodate decimal numbers
b = float(input("User Input: "))
The italicized gets input from the user until s/he enters 0
<em>while not b==0:</em>
<em> newlist.append(b)</em>
<em> b = int(input("User Input: "))</em>
This line sorts the list in ascending order
newlist.sort()
The last element of the sorted list which is the largest element is printed using the next line
print("Largest element is:", newlist[-1])