1/37
Looks like no tags are added yet.
Name | Mastery | Learn | Test | Matching | Spaced |
---|
No study sessions yet.
Indicate constant time complexity in terms of Big-O notation
O(1)
Indicate exponential time complexity in terms of big-O notation
O(2^n)
Find the slowest time complexity
O(n!)
Which notation is consistent for every execution?
O(1)
Which notation grows in proportion to the size of the input
O(n)
Which notation would you usually use for a nest loop?
O(n²)
Indicate polynomial time complexity in terms of big-O notation
O(n²)
1 + 3n + n
Which line best represents the time complexity n!
Red
Which line best represents the time complexity log n
Orange
Which line best represents the time complexity n
Pink
The complexity of Bubble sort algorithm is
O(n²)
If for an algorithm time complexity is given by O(1) then complexity of it is
Constant
The linear/sequential search method to search an element in an array has the complexity of Big(O)?
n
The last index value of an array can be accessed by
array [array.length - 1];
What is the time complexity of following code
O(log N)
If for an algorithm time complexity is given by O(n) then complexity of it is
linear
If for an algorithm time complexity is given by O(1) then complexity of it is
Constant
To measure Time complexity of an algorithm Big O notation is used which:
describes limiting behavior of the function
characterizes a function based on growth of function
upper bound on growth rate of the function
all of the mentioned
all of the mentioned
Big-O notations tell you how long the algorithm will take to complete in standard time
True
False
False
The number of executions grows in proportion to the size of the input
Exponential Time
Linear Time
Polynomial Time
Constant Time
Linear Time
The number of executions grows extremely quickly as the size of the input increases
Exponential Time
Linear Time
Polynomial Time
Constant Time
Exponential Time
The number of executions grows quickly by the input being multiplied by the input
Exponential Time
Linear Time
Polynomial Time
Constant Time
Polynomial Time
What two pieces of information allow you to analyse an algorithm?
Time Complexity
Space Complexity
Size Complexity
Complex Complexity
Simplicity Complex
Time Complexity
Space Complexity
What does a linear time complexity mean?
The amount of time taken to complete an algorithm is independent from the number of elements inputted.
The time taken to complete an algorithm will increase at a smaller rate as the number of elements inputted.
The amount of time taken to complete an algorithm is proportional to the number of items inputted to the power of n
The amount of time taken to complete an algorithm is proportional to 2 to the power of the number of items inputted.
The amount of time taken to complete an algorithm is independent from the number of elements inputted.
What is space complexity?
The space complexity is the amount of storage space an algorithm takes up
How many times a certain number (base) is multiplied together to reach another number.
An algorithm is a series of steps that complete a task
The space complexity is the amount of storage space an algorithm takes up
What order of complexity does this graph represent?
Polynomial
What order of complexity does this graph represent?
Logarithmic
What order of complexity does this graph represent?
Linear
What order of complexity does this graph represent?
Exponential
What order of complexity does this graph represent?
FConstant
What is the time complexity of this algorithm?
O(n)
What is the time complexity of this algorithm?
O(n²)
What is the time complexity of this algorithm?
O(1)
What is the time complexity of this algorithm?
O(2^n)
What is the time complexity of this algorithm?
O(log n)
What is the Big-O Notation of "Divide & Conquer" Algorithms?
O(log n)
What is the Big-O Notation of a combination lock with 4 digits, each digit having 1 of 10 possible values?
O(10^n)