This Python function displays text on the standard output console.
What is print()?
This is the signature needed for every Java application for its execution starting point.
public static void main(String[] args)
This data structure enforces a Last In, First Out (LIFO) access order.
What is a stack?
What value is assigned to myVariable in this Java script?
double myVariable = 5 / 2;
2.0 (must be exact)
This is the first index number of lists/arrays in nearly all modern programming languages.
What is zero?
This Python data type represents an ordered, mutable sequence and is declared with square brackets.
What is a list?
True or False? "String" is one of Java's primitive data types.
False
This is the search algorithm that repeatedly divides an already-sorted list in half.
What is binary search?
What will be output by the following Python script?
count = 0
def increment():
count = 5
increment()
print(count)
0
What decimal value (regular number) is represented by the binary string 1010?
Ten
This keyword defines the start of a custom function in Python.
What is def?
This keyword makes a variable immutable after initialization.
final
This algorithm design breaks a problem into sub problems and stores its results to avoid redundant work.
What is memoization? (Also acceptable: dynamic programming or tabulation)
This error occurs when a recursive function lacks a base case.
What is StackOverflowError (Java) or Recursion error (Python)?
This is the person recognized as the world's first computer programmer after she wrote an algorithm for the Analytical Engine.
Who is Ada Lovelace?
What does the following Python script evaluate to?
True + True + True
3
What is the output of the following Java script?
String s1 = "hello world";
String s2 = new String("hello world");
System.out.println(s1 == s2);
System.out.println(s1.equals(s2));
true
(must be case-sensitive)
This sorting algorithm typically has a time complexity of n*log(n), but has a worst-case time complexity of n^2, depending on its 'pivot.'
What is Quicksort?
What is the output of this Python script?
print("Hello world" * 0)
"" (empty string)
This is the hybrid animal used by GitHub as its mascot.
What is an Octocat?
What is the difference between the "==" operator and the "is" keyword in Python?
"==" checks for equal values, while "is" checks for identical memory locations.
What does the following Java script output?
System.out.println('A' + 'B');
131
20
What happens if the following Python expression is evaluated?
bool("False")
It evaluates to the boolean True.
This is the common term for a malicious piece of code hidden inside an otherwise legitimate-looking software package or library.
What is a Trojan Horse? (also acceptable: Supply-Chain attack)