Linked List MCQ : Guess the Output (Multiple Choice Questions)


Congratulations - you have completed Data Structure.

You scored %%SCORE%% out of %%TOTAL%%.

Your performance has been rated as %%RATING%%


Your answers are highlighted below.
Question 1
Which of the following is correct syntax to print linked list
A
struct node *temp;
do {
    temp = temp->next;
    printf("%d",temp->data);
}while(temp!=NULL);
B
struct node *temp;
do {
    printf("%d",temp->data);
    temp = temp->next;
}while(temp!=NULL);
C
struct node *temp = start;
do {
    temp = temp->next;
    printf("%d",temp->data);
}while(temp!=NULL);
D
struct node *temp = start;
do {
    printf("%d",temp->data);
    temp = temp->next;
}while(temp!=NULL);
Once you are finished, click the button below. Any items you have not completed will be marked incorrect. Get Results
There is 1 question to complete.