NEW
Font size
WorksheetsGDG Code Team Selection Test – Code & Logic Edition
Total questions: 10
Worksheet time: 6mins
1. What is the output of print(2** 3** 2) in Python?
A. 64
B. 512
C. 256
D. 8
2. Which data structure uses FIFO (First In First Out)?
A. Stack
B.Tree
C. Queue
D. Graph
3. What is the time complexity of binary search in a sorted array?
A. O(n)
B. O(n log n)
C. O(log n)
D. O(n²)
4. Which of the following is NOT a valid Java data type?
A. float
B. int
C. char
D. real
5. Which data structure is used in a recursive function call?
A. Queue
B. Stack
C. Array
D. Linked List
6. What is the output of this Java code?
String s = "hello";
System.out.println(s.charAt(1));
A. h
B. e
C. l
D. o
7. What will be the output of the following code?
A. True
B. False
C. Error
D. None
8. What will be the output of this Java snippet?
A. 30
B. 31
C. 32
D. 29
9.What will be the output of the following Python code?
A. 25
B. 10
C. 13
D. 2 + 3 * 2 + 3
10.What is the time complexity of the following code?
A. O(n)
B. O(log n)
C. O(n²)
D. O(n log n)
