EECE7205_Exam1 Review Questions
.pdf
keyboard_arrow_up
School
Northeastern University *
*We aren’t endorsed by this school
Course
7205
Subject
Electrical Engineering
Date
Apr 3, 2024
Type
Pages
4
Uploaded by BaronSummer2048
Page 1
of 4
Northeastern University College of Engineering Department of Electrical & Computer Engineering EECE7205: Fundamentals of Computer Engineering First Midterm Exam Review Questions
For questions Q1
to Q17 choose the best
answer. Make a circle around your letter choice. Q1. In the shown INSERTION-SORT algorithm, to sort list
A
into a decreasing instead of an increasing order, the following change(s) is(are) needed: a. Step 4: i
= j
+1
b. Step 5: while i
> 0 and A
[
i
] < key
c. Step 7: i
= i
+ 1
d. All of the above. Q2. For the INSERTION-SORT algorithm in the previous question. Assume list A has ten
elements and it is already sorted. How many actual lines of code will be executed? a. 45 b. 46 c. 70 d. 80 Q3. The linear search algorithm checks every element in a list sequentially until the desired element is found. If the algorithm is applied on a list of n
elements, then its asymptotic worst and best running times are: a. Θ
(
n
2
) and Θ
(
n
) b. Θ
(2
n
) and Θ
(
n
) c. Θ
(
n
) and Θ
(1) d. None of the above. Q4. Assume f
(
n
) = 2
n
and g
(
n
) = 2
n
/2
, then the following is true: a. f
(
n
) =
Θ
(
g
(
n
))
b. f
(
n
) =
O
(
g
(
n
))
c. f
(
n
) =
Ω
(
g
(
n
))
d. All of the above. Q5. What are the minimum and maximum numbers of elements in a heap of height h
? a. 2
h
and 2
h
+1
- 1
b. 2
h
- 1
and 2
h
+1
c. 2
h-
1
and 2
h
- 1
d. None of the above. Q6. Is the heap represented by an array with values [23, 17, 14, 6, 13, 10, 1, 5, 7, 12] a max-heap? a.
Yes
b. No Q7. What are the leaves of the heap represented by an array with values: [23, 17, 14, 6, 13, 10, 1, 5, 7, 12]? a. [5, 7, 12] b. [7, 12] c. [1, 5, 7, 12] d. [10, 1, 5, 7, 12] Q8. A heap is represented by an array with values A
= [27, 17, 3, 16, 13, 10, 1, 5, 7, 12, 4, 8, 9, 0]. The following will be the contents of A
after applying the operation of MAX-HEAPIFY(
A
, 3)
. a. [27, 17, 10, 16, 13, 9, 1, 5, 7, 12, 4, 8, 3, 0] b. [27, 17, 10, 16, 13, 3, 1, 5, 7, 12, 4, 8, 9, 0] c. [27, 17, 16, 3, 13, 10, 1, 5, 7, 12, 4, 8, 9, 0] d. None of the above
Page 2
of 4
Q9. What is the running time of the HEAPSORT algorithm on an array A
of length n
that is already sorted? a. Θ
(
n
) b. Θ
(
n
lg n
) c. Θ
(lg n
) d. None of the above. Q10. What is the running time of the HEAPSORT algorithm on an array A
of length n
that is initially in reverse sorted order? a. Θ
(
n
) b. Θ
(
n
lg n
) c. Θ
(lg n
) d. None of the above. Q11. Assume an initially empty stack S
stored in array S
[1 .. 6] and the top of the stack is initially S
[1]. What will be the content of S
after the following operations in the sequence PUSH(S,4), PUSH(S, 1), PUSH(S, 3), POP(S), PUSH(S, 8), and POP(S)? a. [4, 1, 3, 8] b. [8, 3, 1, 4] c. [4, 1] d. [3, 8] Q12. Assume an initially empty queue Q
stored in array Q
[1 .. 6] and both its head and tail are pointing to Q
[1]. What will be the content of Q
after the following operations in the sequence ENQUEUE(Q, 4), ENQUEUE(Q, 1), ENQUEUE(Q, 3), DEQUEUE(Q), ENQUEUE(Q, 8), and DEQUEUE(Q)? a. [4, 1, 3, 8] b. [8, 3, 1, 4] c. [4, 1] d. [3, 8] Q13. For hashing by the division method, which of the following is the best choice for the modulus m
? a. 256 b. 181 c. 128 d. 10 Q14. Given a hash table with size m
= 13 and starting index 0
, and a hash function h
(
k
) = k
mod m
. For
k
= 25
, state the hash position (home slot) and the following three positions if linear probing is used for collision resolution. a. 12, 13, 14, 15 b. 11, 12, 13, 14 c. 12, 0, 1, 2 d. 11, 12, 0, 1 Q15. Suppose that we have numbers between 1 and 1000 in a binary search tree, and we want to search for the number 363. Which of the following sequences could not
be the sequence of nodes examined? a.
2, 252, 401, 398, 330, 344, 397, 363.
b.
924, 220, 911, 244, 898, 258, 362, 363.
c.
925, 202, 911, 240, 912, 245, 363.
d.
2, 399, 387, 219, 266, 382, 381, 278, 363.
e.
935, 278, 347, 621, 299, 392, 358, 363.
Q16. What is the maximum number of keys that can be stored in a B-tree of height 2 and minimum degree 3? a. 24 b. 35 c. 124
d. 215 Q17. For a B-tree with a minimum degree 3,
what is its possible maximum height to store 17 keys? a. 2 b. 3 c. 4
d. 5 End of multiple-choice questions
Your preview ends here
Eager to read complete document? Join bartleby learn and gain access to the full version
- Access to all documents
- Unlimited textbook solutions
- 24/7 expert homework help
Related Questions
Design a code converter that converts a decimal digit from
BCD to excess-3 code, the input variables are organized as
(A BC D) respectively with A is the MSB, the output
variables are organized as (W XY Z) respectively with W is
the MSB, put the invalid decimal numbers as don't care.
X= BCD'+B'D+B'C
X= BC'D'+B'D+BC
X= BC'D'+B'D+B'C
X= BC'D'+BD+B'C
arrow_forward
You are to design a number analyzer system which has one 3- bit unsigned integer
number input, and fivel bit outputs as shown below. The outputs are further
explained in the table.
Small
Number
Large
N20
Analyzer
Odd Non-Zero
Even Non-Zero
Prime
Output
Meaning
Small
Ns3
N> 3
N is an odd number
Large
Odd Non-Zero
Even Non-Zero
Nis an even number > 0
N is a prime number
Prime
Your task is to answer following questions:
1. Construct truth table showing input-output relationship
2. Obtain min-term for each output
3. Try to reduce each into optimal SOP form
arrow_forward
USE DIGITAL LOGIC AND DESIGN
Part 1: In Figure_4; we have 4-bit Comparator using 2-bit Comparators block. You have to satisfy given condition by applying all data on figure 4. At the end, given condition should produce HIGH output and other two should be LOW.
A3 A2 A1 A0 = 1101 and B3 B2 B1 B0 = 1110
Figure_4
Part 2: The serial data-input waveform (Data in) and data-select inputs (S0 and S1) are shown in Figure_5. Determine the data-output waveforms from D0 through D3.
Figure_5
Part 3: Decoder can be useful when we have to decode some specific numbers from their equivalent code. Figure 6 has a concept of 3 to 8 line decoder from which you have to generate output waveform from D0 to D7 with proper relationship to input.
Figure_6
Part 4: The data-input and…
arrow_forward
Design a code converter that converts a decimal
digit from BCD to excess-3 code, the input variables
are organized as (A B C D) respectively with A is the
MSB, the output variables are organized as (W XY
Z) respectively with W is the MSB, put the invalid
decimal numbers as don't care.
W=A+BD+BC'
W=A+BD+BC,
W=A'+BD+BC
W= BC'D'+B'D+B'C
arrow_forward
1. An arithmetic system operates with 3-digit decimal numbers with sign presented in BCD (12 bits),
negative numbers utilize the 10's complement form, one decimal digit (4 bits) is occupied by sign: 0 for
"+" and 9 for "-".
1a) Show the most positive and the most negative numbers in both decimal and BCD forms.
1b) Present numbers A=+36 and B= -42 in BCD.
1c) Present the 10's complements of A and B in BCD.
1d) Perform the following operations bit-by-bit, show carries, apply BCD correction (add 6) when
necessary (the sum of two decimal digits is greater than 9).
1d1) A+B in BCD.
1d2) A - B = A+(-B) in BCD by addition of A and the 10's complement of B.
1d3) B-A= B + (-A) in BCD by addition of B and the 10's complement of A.
arrow_forward
Boolean Equation Simplification topic. Thank you.
arrow_forward
Content: Analyze and explain further the step by step answer. Thank you.
arrow_forward
A 32 bit comparator .... Please mark all answersthat are correct (at least one is correct).Is a combinational circuit ARequires only AND and OR gates to be implemented BIs a sequential circuit CCan be implemented using two 16-1 multiplexers DWith minor modifications can be transformed into a shift register E.
solve this question in great detail explaining every single bit of info as i'm a complete beginner and i need to understand how to solve questions of this type. also provide small examples of how the solution would differ if the question was slightly altered
arrow_forward
• SuperNe liı.
A moodle.nct.edu.om
Convert the octal NUMBER 2713. 6464
to hexadecimal number showing the steps
(Note : The problem should be solved in
separate paper with steps and scanned copy
should be submitted along with other answers
Final answer must be entered in the boxes
provided below. For Hexadecimal digits from A to F,
enter their equivalent decimal value in the
corresponding box; do not enter the letter (For eg-
for A, write 10, for B write 11 etc);
Enter only one digit in each box. If there is any
unused box, fill it with 0 -do not leave it blank)
In the written submission, use the letters A to F for
hex digits instead of the values)
Integer part =
Fractional part =
II
arrow_forward
No handwritten please
arrow_forward
Question:If you have two functions F(a,b,c) and G(a,b,c) to implement, what mux size and how many muxes would you need to implement F & G?My Comments:Is it as simple as using two 4-1 multiplexers because it will handle the 6 inputs? Or am I not understanding the function of a multiplexer?
arrow_forward
Convert the 0.333 from decimal real number to a binary number with six places to the right of the radix point using the (a) multiplication method (b) subtraction method. Show your work steps. Hint: stop after finding the six digits following radix point.
arrow_forward
One of the statements below is
incorrect
The microcontroller is a computer
on chip.
The pull-up technique is more
common than pull-down in
electronics parts.
USART can work as UART.
The microprocessor is efficient with
repetitive jobs.
*
arrow_forward
| Solve all parts. Will give thumb's up|
If you can't do all please don't attempt the questions.
arrow_forward
Needs Complete solution with 100 % accuracy.
arrow_forward
Please help me to do this
arrow_forward
Logic Design
courses / EE200SP21 / General / Mid Term Examination Part II (Subjecti
Compute the minimal products of sum and minimal sum of
products expressions for following KMAP. Show your groupings on
KMAP
АВ CD
1
1
1
1
0.
Instructions: You have to solve the answer by hand on paper,
scan/take photo and upload it as a single file.
Local Disk (D:)
Mid Term Examinat.
arrow_forward
Answer all 4 please. For your information last question is true or false
arrow_forward
QUESTION 8
(NEED A NEAT HAND WRITING SOLUTION ONLY OTHERWISE WILL LEAVE A DOWNVOTE)
arrow_forward
Boolean Equation Simplification topic. Please answer both. Thank you.
arrow_forward
In ADC, as you increase the number of bits, you can convert analogue signal to digital signal in smaller steps.
arrow_forward
After executing
MOV AX,-11011
SAHF
JNC WAQIQI
(a) Will the processor jump?
(b) repeat the solution if SAHF is
replaced by SUB AH,18.
arrow_forward
Design a combinational circuit with the four inputs A,B.C, and D, and three outputs
X, Y, and Z. When the binary input is odd number, the binary output is one lesser
than the input. When the binary input is even number the binary output is one greate
than the input. Implement the function using multiplexers with minimal input and
select line.
arrow_forward
I have to submit this as .asm in 2 hour please solve quickly and It's assembly 8051
arrow_forward
Convert the binary NUMBER 11111110001.01110
to decimal number (Show the steps in paper, scan and submit along with other answers)
Decimal no =
Convert the decimal number 14678.972167969 into a HEX NUMBER showing the steps
(Note: The problem should be solved in separate paper with steps and scanned copy should be submitted along with other answers
Final answer must be entered in the boxes provided below.
For Hexadecimal digits from A to F, enter their equivalent decimal value in the corresponding box; do not enter the letter; (For eg, if answer is A, then enter 10, for
B, enter 11 and so on)
Enter only one digit in each box. Also fill the unused boxes with zeros)
However, in your written submissions, use the letters A to F instead of the values
The integer part =
The fractional part =
arrow_forward
A. Use Microsoft Visual Basic to design a form contain two text boxes and one button
called "add", and after click on "add", we get the summation of the numbers
between (10 -30), and display the result on text box1 and get the summation of
the numbers between (60-80) and display the result on text box2.
arrow_forward
Please try typing format please
arrow_forward
Activity 5:
An automated QA machine selects the product in an industry based on the perfection of color,
weight, and length which are expressed by the variables C, W, and L, respectively. If a feature is
perfect the machine takes input as '1', '0' otherwise. Based on the conditions, machine decides
whether to reject (R) a product or not. Assume R = 1, if at least two of the features are not perfect.
Otherwise, R = 0. Solve the following.
arrow_forward
Part 4:
The data-input and data-select waveforms in Figure 7 are applied
to the multiplexer. Determine the output waveform F in relation to the inputs.
DO
D1
D2
D3
1.
so
s1
Figure_7
arrow_forward
SEE MORE QUESTIONS
Recommended textbooks for you
Power System Analysis and Design (MindTap Course ...
Electrical Engineering
ISBN:9781305632134
Author:J. Duncan Glover, Thomas Overbye, Mulukutla S. Sarma
Publisher:Cengage Learning
Related Questions
- Design a code converter that converts a decimal digit from BCD to excess-3 code, the input variables are organized as (A BC D) respectively with A is the MSB, the output variables are organized as (W XY Z) respectively with W is the MSB, put the invalid decimal numbers as don't care. X= BCD'+B'D+B'C X= BC'D'+B'D+BC X= BC'D'+B'D+B'C X= BC'D'+BD+B'Carrow_forwardYou are to design a number analyzer system which has one 3- bit unsigned integer number input, and fivel bit outputs as shown below. The outputs are further explained in the table. Small Number Large N20 Analyzer Odd Non-Zero Even Non-Zero Prime Output Meaning Small Ns3 N> 3 N is an odd number Large Odd Non-Zero Even Non-Zero Nis an even number > 0 N is a prime number Prime Your task is to answer following questions: 1. Construct truth table showing input-output relationship 2. Obtain min-term for each output 3. Try to reduce each into optimal SOP formarrow_forwardUSE DIGITAL LOGIC AND DESIGN Part 1: In Figure_4; we have 4-bit Comparator using 2-bit Comparators block. You have to satisfy given condition by applying all data on figure 4. At the end, given condition should produce HIGH output and other two should be LOW. A3 A2 A1 A0 = 1101 and B3 B2 B1 B0 = 1110 Figure_4 Part 2: The serial data-input waveform (Data in) and data-select inputs (S0 and S1) are shown in Figure_5. Determine the data-output waveforms from D0 through D3. Figure_5 Part 3: Decoder can be useful when we have to decode some specific numbers from their equivalent code. Figure 6 has a concept of 3 to 8 line decoder from which you have to generate output waveform from D0 to D7 with proper relationship to input. Figure_6 Part 4: The data-input and…arrow_forward
- Design a code converter that converts a decimal digit from BCD to excess-3 code, the input variables are organized as (A B C D) respectively with A is the MSB, the output variables are organized as (W XY Z) respectively with W is the MSB, put the invalid decimal numbers as don't care. W=A+BD+BC' W=A+BD+BC, W=A'+BD+BC W= BC'D'+B'D+B'Carrow_forward1. An arithmetic system operates with 3-digit decimal numbers with sign presented in BCD (12 bits), negative numbers utilize the 10's complement form, one decimal digit (4 bits) is occupied by sign: 0 for "+" and 9 for "-". 1a) Show the most positive and the most negative numbers in both decimal and BCD forms. 1b) Present numbers A=+36 and B= -42 in BCD. 1c) Present the 10's complements of A and B in BCD. 1d) Perform the following operations bit-by-bit, show carries, apply BCD correction (add 6) when necessary (the sum of two decimal digits is greater than 9). 1d1) A+B in BCD. 1d2) A - B = A+(-B) in BCD by addition of A and the 10's complement of B. 1d3) B-A= B + (-A) in BCD by addition of B and the 10's complement of A.arrow_forwardBoolean Equation Simplification topic. Thank you.arrow_forward
- Content: Analyze and explain further the step by step answer. Thank you.arrow_forwardA 32 bit comparator .... Please mark all answersthat are correct (at least one is correct).Is a combinational circuit ARequires only AND and OR gates to be implemented BIs a sequential circuit CCan be implemented using two 16-1 multiplexers DWith minor modifications can be transformed into a shift register E. solve this question in great detail explaining every single bit of info as i'm a complete beginner and i need to understand how to solve questions of this type. also provide small examples of how the solution would differ if the question was slightly alteredarrow_forward• SuperNe liı. A moodle.nct.edu.om Convert the octal NUMBER 2713. 6464 to hexadecimal number showing the steps (Note : The problem should be solved in separate paper with steps and scanned copy should be submitted along with other answers Final answer must be entered in the boxes provided below. For Hexadecimal digits from A to F, enter their equivalent decimal value in the corresponding box; do not enter the letter (For eg- for A, write 10, for B write 11 etc); Enter only one digit in each box. If there is any unused box, fill it with 0 -do not leave it blank) In the written submission, use the letters A to F for hex digits instead of the values) Integer part = Fractional part = IIarrow_forward
- No handwritten pleasearrow_forwardQuestion:If you have two functions F(a,b,c) and G(a,b,c) to implement, what mux size and how many muxes would you need to implement F & G?My Comments:Is it as simple as using two 4-1 multiplexers because it will handle the 6 inputs? Or am I not understanding the function of a multiplexer?arrow_forwardConvert the 0.333 from decimal real number to a binary number with six places to the right of the radix point using the (a) multiplication method (b) subtraction method. Show your work steps. Hint: stop after finding the six digits following radix point.arrow_forward
arrow_back_ios
SEE MORE QUESTIONS
arrow_forward_ios
Recommended textbooks for you
- Power System Analysis and Design (MindTap Course ...Electrical EngineeringISBN:9781305632134Author:J. Duncan Glover, Thomas Overbye, Mulukutla S. SarmaPublisher:Cengage Learning
Power System Analysis and Design (MindTap Course ...
Electrical Engineering
ISBN:9781305632134
Author:J. Duncan Glover, Thomas Overbye, Mulukutla S. Sarma
Publisher:Cengage Learning