Linked list deletion
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 5 of 5

Thread: Linked list deletion

  1. #1
    Join Date
    Jul 2013
    Posts
    6

    Linked list deletion

    My code is in the attachment

    the element is not getting deleted can yu tell the mistake i debugged the program but could not find anything
    Attached Files Attached Files
    • File Type: c I1.C (1.0 KB, 441 views)

  2. #2
    Join Date
    Dec 2012
    Location
    England
    Posts
    2,316

    Re: Linked list deletion

    i debugged the program but could not find anything
    The you haven't debugged the program properly!

    Your first problem is here

    Code:
    q=getnode();
    q=start;
    All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.

  3. #3
    Join Date
    Jul 2013
    Posts
    6

    Re: Linked list deletion

    but it is not mattering as i am getting the same result as previous one please help

  4. #4
    Join Date
    Dec 2012
    Location
    England
    Posts
    2,316

    Re: Linked list deletion

    Design the program first before you code. Dry run your design using paper and pencil. Draw boxes for the nodes and lines for the links. When you have the design right, then code the program from the design and then debug the code using the debugger.
    All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.

  5. #5
    Join Date
    Dec 2012
    Location
    England
    Posts
    2,316

    Re: Linked list deletion

    Quote Originally Posted by tendoeschate View Post
    but it is not mattering as i am getting the same result as previous one please help
    As I said in post #2, this is your first problem. What do you expect these 2 lines to accomplish?

    Code:
    q=getnode();
    q=start;
    All advice is offered in good faith only. You are ultimately responsible for effects of your programs and the integrity of the machines they run on.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Azure Activities Information Page

Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center