Linked List

Hello can you please help me in producing the response for the below question since i have an exam tomorrow:

Exercise 4.
Consider the structure used in the project in which a list of students is represented by a ~
set of cells. Each cell contains: ..
. Thename,
. TheID,
. The section number,
. A link to a list ordered by iD.
. A link to a list ordered by name.
Write a function/method that splits into two lists (French and English sections) of the
same type without modifying the original list.

thank you in advanced
Last edited on
(assuming you know basic program structure and how to handle linked list)

//loop
//check if section is english
//add to english list
//else
//add to french list
//end loop

actually i know programing Logic but what I'm asking about it here is the syntax of linked list so you are really appreciated if you write to us the code that should be written here .

thank you in advanced.




Abou Layla
http://cplusplus.com/doc/tutorial/ is the thing you need if you dont know/understand C++

There is no "linked list" syntax in C++. You have to code it using struct/class and adding, deleting, printing functions for the linked list yourself.

Simple struct example is

1
2
3
4
5
struct Node
{
    int data;
    Node *nextNode;
};
Topic archived. No new replies allowed.