June 11, 2021

LOOP Statement – 1 MCQ’s

Read Time:1 Minute, 40 Second

This set of VHDL Multiple Choice Questions & Answers (MCQs) focuses on “LOOP Statement – 1″.

1. Loop is a ________ statement.
a) Concurrent
b) Sequential
c) Assignment
d) Functional

2. How many styles of loop statement does the VHDL have?
a) 2
b) 3
c) 4
d) 5

3. A loop statement is used where we needs to ________
a) Select one from many choices
b) Check a condition
c) Repeat the statements
d) Choose one from two cases

4. Which of the following is correct syntax for defining FOR LOOP?
a)

    label : FOR LOOP loop_specification
     sequential_statements;
     ….
     END LOOP label;

b)

    label : FOR loop_specification LOOP
     sequential_statements;
     ….
     END FOR LOOP;

c)

    label : FOR LOOP loop_specification
     sequential_statements;
     ….
     END FOR LOOP;

d)

    label : FOR loop_specification LOOP
     sequential_statements;
     ….
     END LOOP label 

5. What is the use of FOR loop?
a) To repeat the statement finite number of times
b) To repeat the statement until any condition holds true
c) To repeat the statements for infinite time
d) To repeat statements inside until any condition is false

6. What is the use of WHILE loop?
a) To repeat the statement finite number of times
b) To repeat the statement until any condition holds true
c) To repeat the statements for infinite time
d) To repeat statements inside until any condition is false

7. What is the syntax to use the NEXT statement?
a) NEXT condition loop_label
b) NEXT loop_label WHEN condition
c) loop_label NEXT WHEN condition
d) loop_label NEXT condition

8. Which of the following is correct syntax for WHILE LOOP?
a)

   label: WHILE LOOP specification IS
    sequential_statements;
    END LOOP;

b)

    label: WHILE LOOP condition
    sequential_statements;
    END LOOP label;

c)

    label: WHILE condition LOOP
    sequential_statements;
    END LOOP label;

d)

   label: WHILE specification LOOP
    sequential_statements;
    END LOOP;

9. What does the next statement in loops do?
a) Skips the current iteration
b) Starts the next loop by ending the current
c) Exits the loop
d) Skips the next line of the loop

10. It is not possible to write an infinite loop in VHDL.
a) True
b) False

Happy
Happy
0 %
Sad
Sad
0 %
Excited
Excited
0 %
Sleepy
Sleepy
0 %
Angry
Angry
0 %
Surprise
Surprise
0 %

Average Rating

5 Star
0%
4 Star
0%
3 Star
0%
2 Star
0%
1 Star
0%

Leave a Reply

Your email address will not be published. Required fields are marked *

Previous post WAIT Statements – 3 MCQ’s
Next post LOOP Statement – 2 MCQ’s