Changes

Jump to navigation Jump to search
54 bytes added ,  01:42, 14 December 2016
no edit summary
Line 89: Line 89:     
   while first <=last and not found:  ### this is a while loop that runs the logarithmic structure of the heap sort until the indicated element is found  
 
   while first <=last and not found:  ### this is a while loop that runs the logarithmic structure of the heap sort until the indicated element is found  
       midpoint = (first + last)// 2  ### this is the logic equation of the python code to run, this finds the midpoint element of the array by adding the first and last integer of that array and diving it by 2
+
       midpoint = (first + last)// 2  ### this is the logic equation of the python code to run,  
 +
                                                  ###this finds the midpoint element of the array by adding the first and last integer of that array and diving it by 2
 
       if alist[midpoint] == item ### if the midpoint from the previous equation equates to the indicated integer, then element is found
 
       if alist[midpoint] == item ### if the midpoint from the previous equation equates to the indicated integer, then element is found
 
         found = True
 
         found = True
Cookies help us deliver our services. By using our services, you agree to our use of cookies.

Navigation menu