• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

Sorting Methods with Linked Lists

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'm trying to create 3 different sorting methods (bubble, selection, insertion) that sorts the data in a linked list (custom made). I'm having big time problems with the selection and insertion. I've seen how to do this with arrays, but I just can't seem to make the swap to linked list. I've managed to get the bubble sort to work, but can't seem to get the other two (in fact, I haven't got anything for insertion yet). Here's what I have so far...


Any ideas on what's wrong with the selection sort, and any hints for the insertion? Thanks for all your help!
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic