Deck 3: A: Algorithms

ملء الشاشة (f)
exit full mode
سؤال
Express a brute-force algorithm that finds the second largest element in a list a1, a2, . . . , an Express a brute-force algorithm that finds the second largest element in a list a1, a2, . . . , an   of distinct integers by finding the largest element, placing it at the beginning of the sequence, then finding the largest element of the remaining sequence.<div style=padding-top: 35px> of distinct integers by finding the largest element, placing it at the beginning of the sequence, then finding the largest element of the remaining sequence.
استخدم زر المسافة أو
up arrow
down arrow
لقلب البطاقة.
سؤال
Describe in words how the binary search works.
سؤال
You have supplies of boards that are one foot, five feet, seven feet, and twelve feet long. You need to lay pieces end-to-end to make a molding 15 feet long and wish to do this using the fewest number of pieces possible. Explain why the greedy algorithm of taking boards of the longest length at each stage (so long as the total length of the boards selected does not exceed 15 feet) does not give the fewest number of boards possible.
سؤال
Use the definition of big-O to prove that Use the definition of big-O to prove that  <div style=padding-top: 35px>
سؤال
Describe an algorithm that takes a list of n integers Describe an algorithm that takes a list of n integers   and finds the location of the last even integer in the list, and returns 0 if there are no even integers in the list.<div style=padding-top: 35px> and finds the location of the last even integer in the list, and returns 0 if there are no even integers in the list.
سؤال
Describe an algorithm that takes a list of integers a1, a2, . . . , an Describe an algorithm that takes a list of integers a1, a2, . . . , an   and finds the second-largest integer in the sequence by going through the list and keeping track of the largest and second-largest integer encountered.<div style=padding-top: 35px> and finds the second-largest integer in the sequence by going through the list and keeping track of the largest and second-largest integer encountered.
سؤال
List all the steps that the naive string matcher uses to match the pattern xy in the text yxyxxy.
سؤال
List all the steps that insertion sort uses to sort 8, 20, 13, 16, 9
سؤال
Use the definition of big-O to prove that Use the definition of big-O to prove that  <div style=padding-top: 35px>
سؤال
Use the definition of big-O to prove that Use the definition of big-O to prove that  <div style=padding-top: 35px>
سؤال
Prove or disprove that the cashier's algorithm for making change always uses the fewest coins possible when the denominations available are 1-cent coins, 8-cent coins, and 20-cent coins.
سؤال
Use the definition of big-O to prove that Use the definition of big-O  to prove that   is  <div style=padding-top: 35px> is Use the definition of big-O  to prove that   is  <div style=padding-top: 35px>
سؤال
Describe an algorithm that takes a list of n integers Describe an algorithm that takes a list of n integers   and finds the average of the largest and smallest<div style=padding-top: 35px> and finds the average of the largest and smallest
سؤال
Prove or disprove that the cashier's algorithm for making change always uses the fewest coins possible when the denominations available are pennies (1-cent coins), nickels (5-cent coins), and quarters (25-cent coins).
سؤال
List all the steps that bubble sort uses to sort 8, 20, 13, 16, 9
سؤال
List all the steps the binary search algorithm uses to search for 27 in the following list: 5, 6, 8, 12, 15, 21, 25, 31.
سؤال
Describe an algorithm that takes a list of n integers a1, a2, . . . , an and finds the number of integers each greater than five in the list.
سؤال
Let Let  <div style=padding-top: 35px>
سؤال
Use the definition of big-O to prove that Use the definition of big-O to prove that  <div style=padding-top: 35px>
سؤال
Express a brute-force algorithm that finds the largest product of two numbers in a list a1, a2, . . . , an (n ≥ 2) that is less than a threshold N .
سؤال
Find all pairs of functions in this list that are of the same order: Find all pairs of functions in this list that are of the same order:    <div style=padding-top: 35px> Find all pairs of functions in this list that are of the same order:    <div style=padding-top: 35px>
سؤال
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   A binary search of n elements.<div style=padding-top: 35px>
A binary search of n elements.
سؤال
Arrange the following functions in a list so each is big-O of the next one in the list: Arrange the following functions in a list so each is big-O of the next one in the list:    <div style=padding-top: 35px> Arrange the following functions in a list so each is big-O of the next one in the list:    <div style=padding-top: 35px>
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that lists all ways to put the numbers 1, 2, 3, . . . , n in a row.<div style=padding-top: 35px>
An algorithm that lists all ways to put the numbers 1, 2, 3, . . . , n in a row.
سؤال
Show that Show that  <div style=padding-top: 35px>
سؤال
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
سؤال
Arrange the following functions in a list so each is big-O of the next one in the list: Arrange the following functions in a list so each is big-O of the next one in the list:    <div style=padding-top: 35px> Arrange the following functions in a list so each is big-O of the next one in the list:    <div style=padding-top: 35px>
سؤال
Arrange the functions Arrange the functions   in a list so that each function is big-O of the next function.<div style=padding-top: 35px> in a list so that each function is big-O of the next function.
سؤال
Find the best big-O function for Find the best big-O function for  <div style=padding-top: 35px>
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   A linear search to find the smallest number in a list of n numbers.<div style=padding-top: 35px>
A linear search to find the smallest number in a list of n numbers.
سؤال
Find the best big-O function for Find the best big-O function for  <div style=padding-top: 35px>
سؤال
Suppose you have two different algorithms for solving a problem. To solve a problem of size n, the first algorithm uses exactly Suppose you have two different algorithms for solving a problem. To solve a problem of size n, the first algorithm uses exactly   operations and the second algorithm uses exactly   operations. As n grows, which algorithm uses fewer operations?<div style=padding-top: 35px> operations and the second algorithm uses exactly Suppose you have two different algorithms for solving a problem. To solve a problem of size n, the first algorithm uses exactly   operations and the second algorithm uses exactly   operations. As n grows, which algorithm uses fewer operations?<div style=padding-top: 35px> operations. As n grows, which algorithm uses fewer operations?
سؤال
Prove that Prove that  <div style=padding-top: 35px>
سؤال
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
سؤال
Show that Show that  <div style=padding-top: 35px>
سؤال
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
سؤال
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
سؤال
Prove that Prove that  <div style=padding-top: 35px>
سؤال
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
find the best big-O function for the function. Choose your answer from among the following:    <div style=padding-top: 35px>
سؤال
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the most efficient way to multiply the matrices A1, A2, A3 of sizes 10 × 50, 50 × 10, 10 × 40?
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The best-case analysis of a linear search of a list of size n (counting the number of comparisons)<div style=padding-top: 35px>
The best-case analysis of a linear search of a list of size n (counting the number of comparisons)
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An iterative algorithm to compute n!, (counting the number of multiplications)<div style=padding-top: 35px>
An iterative algorithm to compute n!, (counting the number of multiplications)
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that finds the average of n numbers by adding them and dividing by n<div style=padding-top: 35px>
An algorithm that finds the average of n numbers by adding them and dividing by n
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:  <div style=padding-top: 35px>
The number of print statements in the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:  <div style=padding-top: 35px>
سؤال
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the most efficient way to multiply the matrices A1, A2, A3 of sizes 20 × 5, 5 × 50, 50 × 5?
سؤال
Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm: Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm:  <div style=padding-top: 35px>
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The worst-case analysis of a linear search of a list of size n (counting the number of comparisons)<div style=padding-top: 35px>
The worst-case analysis of a linear search of a list of size n (counting the number of comparisons)
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that prints all bit strings of length n.<div style=padding-top: 35px>
An algorithm that prints all bit strings of length n.
سؤال
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the best order to form the product ABC if A, B and C are matrices with dimensions 8 × 3, 3 × 6 and 6 × 12, respectively?
سؤال
Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm: Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm:  <div style=padding-top: 35px>
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that prints all subsets of size three of the set {1, 2, 3, . . . , n}<div style=padding-top: 35px>
An algorithm that prints all subsets of size three of the set {1, 2, 3, . . . , n}
سؤال
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the best order to form the product ABC if A, B and C are matrices with dimensions 2 × 5, 5 × 7 and 7 × 3, respectively?
سؤال
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:  <div style=padding-top: 35px>
The number of print statements in the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:  <div style=padding-top: 35px>
فتح الحزمة
قم بالتسجيل لفتح البطاقات في هذه المجموعة!
Unlock Deck
Unlock Deck
1/54
auto play flashcards
العب
simple tutorial
ملء الشاشة (f)
exit full mode
Deck 3: A: Algorithms
1
Express a brute-force algorithm that finds the second largest element in a list a1, a2, . . . , an Express a brute-force algorithm that finds the second largest element in a list a1, a2, . . . , an   of distinct integers by finding the largest element, placing it at the beginning of the sequence, then finding the largest element of the remaining sequence. of distinct integers by finding the largest element, placing it at the beginning of the sequence, then finding the largest element of the remaining sequence.
procedure secondmax(a1, a2, . . . , an : integers) procedure secondmax(a1, a2, . . . , an : integers)
2
Describe in words how the binary search works.
To search for x in an ordered list a1, . . . , an, find the "midpoint" of the list and choose the appropriate half of the list. Continue until the list consists of one element. Either this element is x, or else x is not in the list.
3
You have supplies of boards that are one foot, five feet, seven feet, and twelve feet long. You need to lay pieces end-to-end to make a molding 15 feet long and wish to do this using the fewest number of pieces possible. Explain why the greedy algorithm of taking boards of the longest length at each stage (so long as the total length of the boards selected does not exceed 15 feet) does not give the fewest number of boards possible.
The greedy algorithm first chooses a 12-foot-long board, and then three one-foot-long boards. This requires four boards. But only three boards are needed: each five feet long.
4
Use the definition of big-O to prove that Use the definition of big-O to prove that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
5
Describe an algorithm that takes a list of n integers Describe an algorithm that takes a list of n integers   and finds the location of the last even integer in the list, and returns 0 if there are no even integers in the list. and finds the location of the last even integer in the list, and returns 0 if there are no even integers in the list.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
6
Describe an algorithm that takes a list of integers a1, a2, . . . , an Describe an algorithm that takes a list of integers a1, a2, . . . , an   and finds the second-largest integer in the sequence by going through the list and keeping track of the largest and second-largest integer encountered. and finds the second-largest integer in the sequence by going through the list and keeping track of the largest and second-largest integer encountered.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
7
List all the steps that the naive string matcher uses to match the pattern xy in the text yxyxxy.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
8
List all the steps that insertion sort uses to sort 8, 20, 13, 16, 9
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
9
Use the definition of big-O to prove that Use the definition of big-O to prove that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
10
Use the definition of big-O to prove that Use the definition of big-O to prove that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
11
Prove or disprove that the cashier's algorithm for making change always uses the fewest coins possible when the denominations available are 1-cent coins, 8-cent coins, and 20-cent coins.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
12
Use the definition of big-O to prove that Use the definition of big-O  to prove that   is  is Use the definition of big-O  to prove that   is
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
13
Describe an algorithm that takes a list of n integers Describe an algorithm that takes a list of n integers   and finds the average of the largest and smallest and finds the average of the largest and smallest
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
14
Prove or disprove that the cashier's algorithm for making change always uses the fewest coins possible when the denominations available are pennies (1-cent coins), nickels (5-cent coins), and quarters (25-cent coins).
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
15
List all the steps that bubble sort uses to sort 8, 20, 13, 16, 9
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
16
List all the steps the binary search algorithm uses to search for 27 in the following list: 5, 6, 8, 12, 15, 21, 25, 31.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
17
Describe an algorithm that takes a list of n integers a1, a2, . . . , an and finds the number of integers each greater than five in the list.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
18
Let Let
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
19
Use the definition of big-O to prove that Use the definition of big-O to prove that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
20
Express a brute-force algorithm that finds the largest product of two numbers in a list a1, a2, . . . , an (n ≥ 2) that is less than a threshold N .
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
21
Find all pairs of functions in this list that are of the same order: Find all pairs of functions in this list that are of the same order:    Find all pairs of functions in this list that are of the same order:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
22
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:
find the best big-O function for the function. Choose your answer from among the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
23
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   A binary search of n elements.
A binary search of n elements.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
24
Arrange the following functions in a list so each is big-O of the next one in the list: Arrange the following functions in a list so each is big-O of the next one in the list:    Arrange the following functions in a list so each is big-O of the next one in the list:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
25
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that lists all ways to put the numbers 1, 2, 3, . . . , n in a row.
An algorithm that lists all ways to put the numbers 1, 2, 3, . . . , n in a row.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
26
Show that Show that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
27
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:
find the best big-O function for the function. Choose your answer from among the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
28
Arrange the following functions in a list so each is big-O of the next one in the list: Arrange the following functions in a list so each is big-O of the next one in the list:    Arrange the following functions in a list so each is big-O of the next one in the list:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
29
Arrange the functions Arrange the functions   in a list so that each function is big-O of the next function. in a list so that each function is big-O of the next function.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
30
Find the best big-O function for Find the best big-O function for
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
31
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   A linear search to find the smallest number in a list of n numbers.
A linear search to find the smallest number in a list of n numbers.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
32
Find the best big-O function for Find the best big-O function for
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
33
Suppose you have two different algorithms for solving a problem. To solve a problem of size n, the first algorithm uses exactly Suppose you have two different algorithms for solving a problem. To solve a problem of size n, the first algorithm uses exactly   operations and the second algorithm uses exactly   operations. As n grows, which algorithm uses fewer operations? operations and the second algorithm uses exactly Suppose you have two different algorithms for solving a problem. To solve a problem of size n, the first algorithm uses exactly   operations and the second algorithm uses exactly   operations. As n grows, which algorithm uses fewer operations? operations. As n grows, which algorithm uses fewer operations?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
34
Prove that Prove that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
35
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:
find the best big-O function for the function. Choose your answer from among the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
36
Show that Show that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
37
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:
find the best big-O function for the function. Choose your answer from among the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
38
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:
find the best big-O function for the function. Choose your answer from among the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
39
Prove that Prove that
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
40
find the best big-O function for the function. Choose your answer from among the following: find the best big-O function for the function. Choose your answer from among the following:
find the best big-O function for the function. Choose your answer from among the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
41
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the most efficient way to multiply the matrices A1, A2, A3 of sizes 10 × 50, 50 × 10, 10 × 40?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
42
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The best-case analysis of a linear search of a list of size n (counting the number of comparisons)
The best-case analysis of a linear search of a list of size n (counting the number of comparisons)
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
43
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An iterative algorithm to compute n!, (counting the number of multiplications)
An iterative algorithm to compute n!, (counting the number of multiplications)
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
44
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that finds the average of n numbers by adding them and dividing by n
An algorithm that finds the average of n numbers by adding them and dividing by n
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
45
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:
The number of print statements in the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
46
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the most efficient way to multiply the matrices A1, A2, A3 of sizes 20 × 5, 5 × 50, 50 × 5?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
47
Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm: Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
48
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The worst-case analysis of a linear search of a list of size n (counting the number of comparisons)
The worst-case analysis of a linear search of a list of size n (counting the number of comparisons)
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
49
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that prints all bit strings of length n.
An algorithm that prints all bit strings of length n.
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
50
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the best order to form the product ABC if A, B and C are matrices with dimensions 8 × 3, 3 × 6 and 6 × 12, respectively?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
51
Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm: Give a big-O estimate for the number of operations (where an operation is an addition or a multiplication) used in this segment of an algorithm:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
52
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   An algorithm that prints all subsets of size three of the set {1, 2, 3, . . . , n}
An algorithm that prints all subsets of size three of the set {1, 2, 3, . . . , n}
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
53
assume that the number of multiplications of entries used to multiply a p × q and a q × r matrix is pqr.
What is the best order to form the product ABC if A, B and C are matrices with dimensions 2 × 5, 5 × 7 and 7 × 3, respectively?
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
54
find the "best" big-O notation to describe the complexity of the algorithm. Choose your
answers from the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:
The number of print statements in the following: find the best big-O notation to describe the complexity of the algorithm. Choose your answers from the following:   The number of print statements in the following:
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.
فتح الحزمة
k this deck
locked card icon
فتح الحزمة
افتح القفل للوصول البطاقات البالغ عددها 54 في هذه المجموعة.