
Singly and Doubly Linked List Quiz

Quiz
•
Other
•
University
•
Hard

Niveditha N
Used 1+ times
FREE Resource
17 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which line correctly defines a Node in a singly linked list?
class Node {
int data;
Node next;
Node(int d) {
_______________; // ← Fill this}}
this.next = d;
data = d; next = null;
this.data = next;
data = next;
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What should go in the blank?
void insertAtHead(int data) {
Node newNode = new Node(data);
newNode.next = ___________; // ← Fill this
head = newNode;}
null
head
newNode
head.next
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
(Double)Which is correct?class DNode {
int data;
DNode next, prev;
DNode(int d) {
data = d;
next = null;
_________; // ← Fill }}
prev = d;
prev = null;
d = prev;
prev = next;
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which line completes the logic?(Double)
DNode newNode = new DNode(data);
newNode.next = head;
if (head != null)
head.__________ = newNode;
head = newNode;
next
prev
data
pointer
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Complete the code to print the list in reverse:(double)
DNode temp = tail;
while (temp != null) {
System.out.print(temp.data + " ");
temp = ___________;
}
temp.next
temp.prev
head.prev
temp.back
Create a free account and access millions of resources
Similar Resources on Wayground
21 questions
Circular Linked List Quiz

Quiz
•
University
20 questions
CodeMavarick

Quiz
•
University
20 questions
UTS - Struktur Data

Quiz
•
University
14 questions
In-Lab5

Quiz
•
University
15 questions
Das Quiz von Lektion 1

Quiz
•
10th Grade - Professi...
20 questions
381 Unit 2 Review Session

Quiz
•
University
18 questions
EKG dasar gangguan impuls

Quiz
•
University
20 questions
Basic Statistics

Quiz
•
University
Popular Resources on Wayground
10 questions
SR&R 2025-2026 Practice Quiz

Quiz
•
6th - 8th Grade
30 questions
Review of Grade Level Rules WJH

Quiz
•
6th - 8th Grade
6 questions
PRIDE in the Hallways and Bathrooms

Lesson
•
12th Grade
10 questions
Lab Safety Procedures and Guidelines

Interactive video
•
6th - 10th Grade
10 questions
Nouns, nouns, nouns

Quiz
•
3rd Grade
25 questions
Multiplication Facts

Quiz
•
5th Grade
11 questions
All about me

Quiz
•
Professional Development
15 questions
Subtracting Integers

Quiz
•
7th Grade
Discover more resources for Other
15 questions
Let's Take a Poll...

Quiz
•
9th Grade - University
2 questions
Pronouncing Names Correctly

Quiz
•
University
34 questions
WH - Unit 2 Exam Review -B

Quiz
•
10th Grade - University
21 questions
Mapa países hispanohablantes

Quiz
•
1st Grade - University
10 questions
Transition Words

Quiz
•
University
5 questions
Theme

Interactive video
•
4th Grade - University
25 questions
Identifying Parts of Speech

Quiz
•
8th Grade - University
10 questions
Spanish Greetings and Goodbyes!

Lesson
•
6th Grade - University