I know a code review wasn't the main goal of you message but I feel
it's worth mentioning two tips:
On 22 December 2016 at 01:55, Deborah Swanson wrote:
> ls = []
> with open('E:\\Coding projects\\Pycharm\\Moving\\New Listings.csv',
> 'r') as infile:
> raw = csv.reader(infile)
>
> On Thu, Dec 22, 2016 at 11:55 AM, Deborah Swanson
> wrote:
> > The problem is that while mergeSort puts the list ls in
> perfect order,
> > which I can see by looking at result on merge's final return to
> > mergeSort, and at the left and the right once bac
On Thu, Dec 22, 2016 at 11:55 AM, Deborah Swanson
wrote:
> The problem is that while mergeSort puts the list ls in perfect order,
> which I can see by looking at result on merge's final return to
> mergeSort, and at the left and the right once back in mergeSort. Both
> the left h
rows = indata.__len__()
for i in range(rows):
ls.append(indata[i])
# sort: Description only, to make hyperelinks & find duplicates
mergeSort(ls)
# find & mark dups, make hyperlink if not dup
for i in range(1, len(ls) - 1):
if ls[i][0]
On Wed, 09 Aug 2006 12:50:11 -0700, ben81 wrote:
> Hi,
>
> the following code is adopted PseudoCode from Introduction to
> Algorithms (Cormen et al).
I'm assuming you are doing this as a learning exercise, because -- trust
me on this -- nothing you write in pure Python code will come within coo
i +=1
else:
A[k] = R[j]
j +=1
def mergeSort(A,p,r):
if p < r:
q=(p+r)/2
mergeSort(A,p,q)
mergeSort(A,q+1,r)
merge(A,p,q,r)
--
http://mail.python.org/mailman