Thread: cirular linked list

  1. #1
    Registered User
    Join Date
    Aug 2004
    Posts
    36

    cirular linked list

    hi everyone,
    i have a complex query
    i want to make a circular linked list where i have to
    1) insert a task into the scheduler list before scheduler begins
    2) this first task will add another tasks into scheduler list
    3) the scheduler will do circular operation .if one tasks has finished it will go to the new task
    can anyone help me
    i am using gcc

  2. #2
    Registered User
    Join Date
    Sep 2004
    Posts
    719
    Quote Originally Posted by warney_out
    can anyone help me

    yes - i can help. NEXT!
    i seem to have GCC 3.3.4
    But how do i start it?
    I dont have a menu for it or anything.

  3. #3
    Chief Code Coloniser!
    Join Date
    Apr 2005
    Posts
    121
    What misplaced is trying to say is "try it yourself, and see how you go before you ask questions".

  4. #4
    Registered User
    Join Date
    Sep 2004
    Posts
    719
    Quote Originally Posted by TheColonial
    What misplaced is trying to say is "try it yourself, and see how you go before you ask questions".

    ....or at the very least, ask a specific question
    i seem to have GCC 3.3.4
    But how do i start it?
    I dont have a menu for it or anything.

  5. #5
    ATH0 quzah's Avatar
    Join Date
    Oct 2001
    Posts
    14,826
    Quote Originally Posted by kermi3
    Welcome to the boards. If you haven't already done so then please take some time to familiarise yourself with the faq:
    http://faq.cprogramming.com/cgi-bin/smartfaq.cgi

    Make sure you have a look at the the posting guidelines:
    http://cboard.cprogramming.com/annou...ouncementid=51
    Following the rules will ensure you get a prompt answer to your question.

    Remember, too, that the board has a search facility, a link is at the top of your screen:
    http://cboard.cprogramming.com/search.php
    It will often get you a quicker answer to your questions than waiting for a response to one you have posted.

    It appears that you are posting a homework assignment or other project.

    Please don't ask people to do all your work for you, See the announcement on Homework at the top of all forums to see what is acceptable or PM me. Basically people are happy to help, but they're not going to do it all for you.

    Show us what you've got, show your code (using code tags), or where you're confused and someone will be happy to help you I'm sure. If it's something that you absolutely don't understand how it works, like you have no clue how qsort works, then ask a general question about the function and I'm sure someone will explain it. Though they may not give you all of the code for it, but someone will explain the concept.


    On obivous homework questions especially, I like to remind people of the board's ninth guildeline, while this board is very helpful to people, make sure you have your instructor's permission before seeking help on assignments. While people on these boards are more than happy to help, we discourage people from asking for help on graded work without the instructor's permission, and we claim no repsonsibilty for any cheating or honor violations.

    Feel free to PM me with any questions.

    Good Luck,

    Kermi3
    Read and follow the above instructions, and try your post (in the same thread) again. Oh, and while you're at it, in the FAQ there is a rather nice tutorial on linked lists. Plus, were you to search the forums for said topic, you'll find a huge number of posts on the topic.

    Quzah.
    Hope is the first step on the road to disappointment.

  6. #6
    Registered User
    Join Date
    Aug 2004
    Posts
    36
    what i meant to say was i need some pseudo codes or algorithm on how can i solve my problem.
    i have to make a scheduler
    Code:
     
    
    scheduler()
    {
    it will contain the list of the taks in the queue and executes the task that is in the list
     }
    
    addtasks()
    {
    this function will add the tasks into the scheduler
    }
    task0()
    {
    it will add task1 and task2 into scheduler list
    }
    task2()
    {
    this will perform some other task
    }
    task2()
    {
    this will perform some other task
    }
    the thing i have to do is add task0 in the list even before the scheduler starts.I need some guidelines as to how i can perform the scheduling and how to put tasks into the queue.
    all the tasks have same priority so what ever task is in the list next will be executed.this is circular queue.
    i have already done the codes for task 1 and task2
    i hope this has cleared the air to certain extent

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. C++ Linked list program need help !!!
    By dcoll025 in forum C++ Programming
    Replies: 1
    Last Post: 04-20-2009, 10:03 AM
  2. single linked list to double linked list (help)
    By Countfog in forum C Programming
    Replies: 8
    Last Post: 04-29-2008, 08:04 PM
  3. Reverse function for linked list
    By Brigs76 in forum C++ Programming
    Replies: 1
    Last Post: 10-25-2006, 10:01 AM
  4. Template Class for Linked List
    By pecymanski in forum C++ Programming
    Replies: 2
    Last Post: 12-04-2001, 09:07 PM
  5. singly linked list
    By clarinetster in forum C Programming
    Replies: 2
    Last Post: 08-26-2001, 10:21 PM