#We start by initializing our two lists
unsorted_list = [3,13,8,5,19,1]
sorted_list = []
while len(unsorted_list) >0 : #As long as there are elements in the first list continue
smallest_entry = unsorted_list[0] #Find the smallest entry and store the position (similar to Task 3.3 and 3.4)
index_to_delete = 0 #We want to know the index and value of the smallest element
#Our initial guess is the first element of the list and we will update during the for-loop if we find smaller elements
for index in range(0,len(unsorted_list)):
entry = unsorted_list[index] #Retrieve the current list entry
if entry < smallest_entry: #We update our estimate of the smalles entry
smallest_entry = entry #We store the smallest entry
index_to_delete = index #We also store its position
sorted_list.append(smallest_entry) #Add the smallest entry to the second list
del unsorted_list[index_to_delete] #Delete the list in the old list
print(sorted_list) #Print the result in the end