
IB Option D HL
Quiz
•
Computers
•
12th Grade
•
Practice Problem
•
Medium
Robert Morrison
Used 8+ times
FREE Resource
Enhance your content in a minute
9 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Choose the best definition of 'object reference'
A variable that contains an object
A variable that points to an object
A variable that instantiates an object
A unique hash code that identifies a particular object in memory
2.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Which statements about recursion are correct?
Recursive algorithms must have a base case and a general case
Recursion is rarely used in practice (in the context of high-level programming)
Recursive algorithms are somewhat memory-intensive
There are some problems for which the solution can be expressed much more simply with recursion
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Presume a is an object reference. z is a new object reference, which is initially assigned to a. Which statement is most correct?
z will always reference the same object as a
z references a different object that is an identical copy of the object referenced by a
z references the same object as a, but if a is reassigned, z will continue to reference the original object
z references a different object than a, but of the same class
4.
DRAG AND DROP QUESTION
1 min • 1 pt
ArrayList and LinkedList are two classes which (a) the (b) (c) . As a result, they have the same (d) . The underlying implementation of these two classes is (e) , but they can be used in an identical way.
5.
FILL IN THE BLANK QUESTION
1 min • 1 pt
You are defining a Node class for a singly linked list. Write the line of code that defines a pointer to the subsequent Node as an instance variable. Use the object reference 'next'. Do not initialise the instance variable.
6.
MULTIPLE SELECT QUESTION
45 sec • 1 pt
Which of the following are considered good software development practices?
Using existing library classes instead of manually re-implementing existing functionality
Making use of indentation and spacing to aid readability
Writing methods using as few lines of code as possible
Ensuring the precise function of all code is described clearly through comments
Answer explanation
Code should be self-documenting through use of modularity, meaningful identifiers and short, clear code statements. Comments should only be used sparingly, or to produce class documentation (e.g. Javadoc)
Code should be as clear as possible - the number of lines doesn't matter (within reason). In many cases, one action per line is much clearer and will execute just as efficiently as a single long, complex line of code that performs many functions.
7.
MATCH QUESTION
1 min • 1 pt
Match the following List interface methods with their description
Deletes the item at position index
return(int index)
Returns the number of items in the List
add(Object item)
Not a real List method!
remove(int index)
Inserts item at position index
size()
Inserts item to the end of the list
add(int index, Object item)
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
12 questions
ICT Computer Basics pt1
Quiz
•
10th - 12th Grade
10 questions
Recursion Practice, Recursion Practice, Recursion Practice...
Quiz
•
10th Grade - University
10 questions
Social media influencers
Quiz
•
6th - 12th Grade
10 questions
1.1 - System Architecture - CPU [OCR] [GCSE]
Quiz
•
9th - 12th Grade
12 questions
website design elements
Quiz
•
12th Grade
10 questions
ICT as Social Change
Quiz
•
12th Grade
14 questions
LA7.C7: Turtle Graphics
Quiz
•
9th Grade - University
11 questions
Packet Switching and Encryption
Quiz
•
10th - 12th Grade
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
