0% found this document useful (0 votes)
3K views

Software Fundamentals

The document provides a quiz on software fundamentals concepts like algorithms, flowcharts, pseudocode and selection statements. It contains 15 multiple choice questions testing understanding of these topics through problems and code snippets.

Uploaded by

Kishan Patel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3K views

Software Fundamentals

The document provides a quiz on software fundamentals concepts like algorithms, flowcharts, pseudocode and selection statements. It contains 15 multiple choice questions testing understanding of these topics through problems and code snippets.

Uploaded by

Kishan Patel
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 77

SOFTWARE FUNDAMENTALS

Check Your Understanding (Introduction to


Alogorithms,Flowcharts & Psuedocode
1. Which of the following represents the correct sequence for the
given pseudo-code?
BEGIN
-------------
-------------
-------------
-------------
END

DECLARE variables – number1, number2, result


result <- number1 * number2
READ number1 and number2
PRINT result
DECLARE variables – number1, number2, result
READ number1 and number2
PRINT result
result <- number1 * number2
READ number1 and number2
DECLARE variables – number1, number2, result
result <- number1 * number2
PRINT result
DECLARE variables – number1, number2, result
READ number1 and number2
result <- number1 * number2
PRINT result

2. Expression is a combination of ___________, ____________


and _______________
Select one or more:
functions
operators
variables
constants
keywords

3. Identify the meaningful variable names which can be used?


Select one or more:
1num
user1
$register_number
user name

4. Rearrange the pseudo-code for multiplying two given numbers,


Choose the correct option from the below.
1 BEGIN
2 result <- number1 * number2
3 PRINT result
4 READ number 1 and number 2
5 DECLARE variables – number1, number2, result
6 END

145236
154236
154326
145326

5. Match the appropriate Flowchart symbols with its purpose.

Flow direction
Answer 1

Input/output
Answer 2

Connector
Answer 3

Decision making
Answer 4

Process
Answer 5

Start/Stop
Answer 6
6. Examine the correct logic with their descriptions

BEGIN

DECLARE
radius,circumference

READ radius

circumference <---- Answer 1


2*3.14*radius calculating the perimeter of a circle

PRINT circumference

END

BEGIN

DECLARE mark1, mark2,


mark3, average

READ mark1, mark2, mark3

average <- Answer 2


(mark1+mark2+mark3)/3 finding the average mark of three subjects

PRINT average

END

BEGIN Answer 3
calculating simple interest problem
DECLARE principal,
number_of_years,
rate_of_interest,result

READ principal,
number_of_years, rate_of_interest

result <---(principal*
number_of_years*,
rate_of_interest)/100

PRINT result

END

7. Match the symbols and flowchart to its appropriate functionality

Diamond Answer 1 Decision making

Parallelogram Answer 2 Input/output

Rectangle Answer 3 Process

8. Choose the correct arrangement of mathematical symbols to


make the equation true.
600 [+] 400 [-] 800 [×] 300 [/] 200 = 200
600 [-] 400 [+] 800 [/] 300 [×] 200 = 200
600 [/] 400 [+] 800 [-] 300 [×] 200 = 200
600 [×] 400 [/] 800 [-] 300 [+] 200 = 200
9. Flow chart for adding numbers

Is the given flowchart correct?Select one:


The symbol for process is incorrect
The symbol for start/stop is incorrect
The flowchart has no error
The symbol for reading input from the user is incorrect

10. Arrange the words given below in a meaningful sequence.

1. Word 2. Paragraph 3. Sentence 4. Letters 5. phrase

Select one:
4,1,5,2,3
4,1,3,5,2
4,2,5,1,3
4,1,5,3,2
11. Stephany is learning to draw a flowchart to calculate the area
of a circle. Select the appropriate option that would fit into the
process section of the flow chart?
Select one:
Print the area
Area=3.14*radius*radius
Check if radius has positive value
Read the value of radius

12. An algorithm described in the form of programming language


is Pseudo code

13. Which of the following represents the correct sequence for the
given algorithm?
Get the two numbers.
Start
Add the two numbers and store the result in sum.
Display the sum value.
Stop
Start
Get the two numbers.
Display the sum value.
Add the two numbers and store the result in sum.
Stop
Start
Get the two numbers.
Add the two numbers and store the result in sum.
Display the sum value.
Stop

Start
Add the two numbers and store the result in sum.
Get the two numbers.
Display the sum value.
Stop

14. Which of the following represents the correct sequence for the
given pseudo-code?
BEGIN
[1] READ mark1, mark2, mark3, mark4, mark5
[2] PRINT average
[3] total < mark1 + mark2 + mark3 + mark4 + mark5
[4] average < total / 5
[5] DECLARE mark1, mark2, mark3, mark4, mark5, total,
average
END

51432
15432
15342
51342

15. Choose the correct and meaningful pseudo-code to add two


numbers?
Select one:
Start the process
READ a,b
ADD a,b and store it in sum
Display sum
Stop
BEGIN
READ a, b
sum=a+b
PRINT sum
END
BEGIN
READ a, b
sum=add(a,b)
DISPLAY sum
END
BEGIN
DECLARE number1,number2,sum
READ number1,number2
sum<----number1+number2
PRINT sum
END

Selection Statements - Crack the puzzles


1. Assume, there are four boys sitting on a sofa. Mithran is to the
left of Anwar. Babu is to the right of Anwar. Edwin is between
Anwar and Babu. Who would be second from the left in the
photograph?Select one:

Anwar
Edwin
Mithran
Babu

2. Pointing to a photograph of a boy Mathew said, "He is the son


of the only son of my mother." How is Mathew related to that
boy?Select one:

Uncle
Cousin
Father
Brother

3. Analyze the statements.


i)Danny is younger than Edwin
ii)Christine is younger than Danny.
iii)Christine is older than Edwin.
If the first two statements are true, the third statement is
Select one:
False
uncertain
True
Pseudocode Using Selection Statements - Quiz
1. Silvester and Tweety are friends. Bender was one of the
Silvester's enemy. One day Silvester and Tweety went on to a
trip. Bender planned to kidnap Tweety.. He kidnapped and kept
her in one of the hot balloons tied up to a height. There were 50
hot balloons numbered from one. Each balloon will fly to a certain
height. Only the numbers having both 3 and 7 as its factors can
fly upto the height of the Tweety's balloon. Silvester was confused
and he didn't know which numbered balloon can fly to Tweety.
(Note: If balloon number is greater than 50, or balloon number
less than 1, then it should display invalid balloon number)

Eg: Balloon's number:42

This balloon can fly to Tweety.

Eg:Enter the Balloon's number:24

This balloon cannot fly to Tweety.

Pseudocode :
2. Choose the correct pseudocode for the below problem
statement.
Problem Statement :
Hide and Seek
One day, Bunny and his friends were playing hide and seek in the
forest. Tom went along to hide. He finds an abandoned bag
containing a board(8x8) game in a cave. He gets excited and
starts playing the game only to realizes that it's magical. He has
three chances to roll the dice. Each turn's outcome will lead into a
new surrounding and some would be dangerous. If the outcome
of rolling dices is in multiples of 3 then he will be caught in a
dangerous phase.
Note if any one outcome is multiple of 3, then tom is in danger.
(If the outcome of rolling dices is either 0 or less than that you
should tell Tom as "Invalid Turn". )

Example :
Enter value of turn 1
10
Enter value of turn 2
5
Enter value of turn 3
2
Tom is safe

Example :
Enter value of turn 1
12
Enter value of turn 2
5
Enter value of turn 3
2
Tom is in danger

BEGIN
DECLARE variables turn1,turn2,turn3
READ turn1, turn2, turn3
IF turn1>0 AND turn2>0 AND turn3>0 THEN
ELSE
PRINT "Tom is Safe"
IF turn1%3==0 OR turn2%3==0 OR turn3%3==0 THEN
PRINT "Tom is in Danger"
END IF
ELSE
PRINT "Invalid turn"
END IF
END

BEGIN
DECLARE variables turn1,turn2,turn3
READ turn1, turn2, turn3
PRINT "Tom is in Danger"
IF turn1>0 AND turn2>0 AND turn3>0 THEN
ELSE
PRINT "Tom is Safe"
IF turn1%3==0 OR turn2%3==0 OR turn3%3==0 THEN
END IF
ELSE
PRINT "Invalid turn"
END IF
END

BEGIN
DECLARE variables turn1,turn2,turn3
READ turn1, turn2, turn3
IF turn1>0 AND turn2>0 AND turn3>0 THEN
IF turn1%3==0 OR turn2%3==0 OR turn3%3==0 THEN
PRINT "Tom is in Danger"
ELSE
PRINT "Tom is Safe"
END IF
ELSE
PRINT "Invalid turn"
END IF
END

Selection Statements-Check Your Understanding


1.A computer program must either use conditional statements or
looping statements or sequential statements to solve a problem.
All of them must not appear in the same program. State true/
false.
Select one:
True
False
2. From the option, find the correct pseudo-code to find the
greatest of three numbers
Select one:
BEGIN
DECLARE variables a,b,c
READ a,b,c
IF a>c
PRINT “a”
ELSE
PRINT “c”
ELSE IF b>c
PRINT “b”
ELSE
PRINT “c”
END
BEGIN
DECLARE variables a, b, c
READ a, b, c
IF a<b
IF a<c
PRINT “a”
ELSE
PRINT “c”
ELSE IF b<c
PRINT “b”
ELSE
PRINT “c”
END
BEGIN
DECLARE variables a,b,c
READ a,b,c
IF a>b
IF a>c
PRINT “a”
ELSE
PRINT “c”
ELSE IF b>c
PRINT “b”
ELSE
PRINT “c”
END

3. If there are 6 chocolates and you take away 4, how many do


you have?
Select one:
None
2
4
6

4. ______________must be used when a set of statements


needs to be executed only if a condition is met.
Select one:
Either selection or looping statements
selection statements
Looping statements

5. Manual execution of the steps in the algorithm is called as


_____
Select one:
Execution
Simple Run
compiling
Dry run

6. Which of the following is not a keyword used in a pseudo-code


Select one:
Start
End if
static
Read

7. Which of the keyword is used to close the IF block, while


writing a pseudo-code?
Select one:
End if
Else if
End
Else

8. Arrange the pseudo-code logic for checking a number divisible


by 5 or 11.

 BEGIN
 DECLARE number
READ number
 IF number%5==0
 THEN
PRINT “number divisible by 5”
 ELSE IF number%11==0
 THEN
PRINT “number divisible by 11”
 ELSE
PRINT ““number not divisible by 5 or 11”
 END IF
 END

9. Consider the pseudo-code snippet. What output do you think


the snippet will produce if the sample input for number is 3?

BEGIN
DECLARE number
READ number
IF number>=0
IF number == 0
PRINT “Zero”
ELSE
PRINT “Three”
ENDIF
PRINT “No Value”
END
Select one:
Zero Three No value
Three No value
Zero Three
Zero No value
10. When a single if-else logic is used, how many possible
choices can be there?Select one:
3
2
0
1

11. What do you infer from this statement?


“Only if Alvin is happy, then he does not go to work.”
Select one:
Alvin is not happy and he does not go to work
Alvin is happy and he goes to work.
Alvin is not happy and he goes to work.
Alvin is happy and he does not go to work

12. READ age


IF age>18
THEN
PRINT “Eligible to vote”
ENDIF The given pseudo-code snippet is an example for_______
Select one:
Simple If logic
Else if ladder logic
Sequence Logic
Nested if logic
13. Try some!!!
If a doctor gives you 3 pills and tells you to take one pill every half
hour, how long would it take before all the pills had been taken?
Select one:
2 hours
3 hours
1 hour
1 and half hour

14. By default, the flow of a program is________


Select one:
top to bottom
bottom to top
iterative
conditional

15. Identify the correct pseudo-code logic for checking a number


divisible by 5 or 11.
DECLARE number
IF number%5==0
THEN
PRINT “number divisible by 5”
ELSE IF number%11==0
THEN
PRINT “number divisible by 11”
ELSE
PRINT “number not divisible by 5 or 11”
END IF
READ number
BEGIN
BEGIN
DECLARE number
READ number
IF number%5==0
THEN
PRINT “number divisible by 5”
ELSE IF number%11==0
THEN
PRINT “number divisible by 11”
ELSE
PRINT “number not divisible by 5 or 11”
END IF
END
DECLARE number
READ number
IF number%5==0
THEN
PRINT “number divisible by 5”
ELSE IF number%11==0
THEN
PRINT “number divisible by 11”
ELSE
PRINT “number not divisible by 5 or 11”
END
BEGIN
DECLARE number
READ number
IF number%5==0
THEN
PRINT “number divisible by 5”
ELSE IF number%11==0
THEN
PRINT “number divisible by 11”
ELSE
PRINT “number not divisible by 5 or 11”
END IF

16. You are returning home from a hotel. On the way, you find a
sealed envelope in a street, fully addressed with unused stamps
on it. What would you do???
Select one:
Open the envelope, find out who has dropped it by mistake,
and send it to him if possible.
Leave the envelope there as it was and walk away
Remove the unused stamps and destroy the envelope.
post it at the nearest mail box.

17. Identify the logic which suits the flowchart


Select one:
Nested if
Simple if
Else-if Ladder if else

18. Which statement logic implements multiple-way selection?


Select one:
Sequential
Simple if
If-else
Else if ladder

19. Decision statements are also called as _______________.


Sequence logic
Program logic
Iteration logic
Selection logic

20. Go to statements in the algorithm is…


Select one:
Used to apply decisions in a program
Used in sequential arrangement of steps
Used to iterate the sequence of steps
Used to alternate the flow of the program

21. Choose the correct options to complete the pseudo-code and


determine whether the number is positive, zero, or negative.
BEGIN
DECLARE number
READ number
IF _________
PRINT “Number is positive”
IF _________
PRINT “Number is zero”
IF _________
PRINT “Number is Negative”
END IF
END
number>0, number>0, number==0
number>0, number==0, number<0
number>0, number==0, number==0
number<0, number>0, number==0
Looping statements-Crack the Puzzles
1. Find out the logic of series and complete.
9 = 4, 21 = 9, 22 = 9, 24 = 10, 8 = 5, 7 = 5, 99 = 10, 100 = 7, 16 =
?
Select one:
6
7
9

2. Match the following:

I am an odd number; take away an alphabet and I Answer 1


become even. What am I? 7

Multiply me by myself and you will get the equivalent Answer 2


of adding me to myself.what am I? 2

I am a number with a couple of friends, quarter a Answer 3


dozen, and you'll find me again. What am I? 3

3. Take 1 away from me and you get a prime number; add 1 to


me and you get twice that prime number.
Select one:
5
3
6
Pseudocode using Loops – Quiz
1. Select the appropriate code snippet for the given problem
statement provided as pseudocode.
Problem Statement :
Strong number
Check if a given number is a strong number. 145 is a strong
number because 1!+4!+5! = 145.
Sample Input :
145
Sample Output :
Strong number
Code:
BEGIN
DECLARE variables number, sum, temp, remainder, fact
READ number
SET sum=0, temp=number
remainder = number % 10
SET fact = 1
FOR i IN 1 to remainder DO
fact = fact *i
END FOR
sum = sum+ fact
number = number / 10
END WHILE
IF sum==temp THEN
PRINT "Strong number"
ELSE
PRINT "Not a Strong number"
END IF
END

WHILE number < 0


WHILE number != 0
WHILE number <= 0
WHILE number == 0

2. Choose the pseudocode for the below problem statement.


Problem Statement :
Vehicle Registration
Mr.William buys a new Audi car. During the vehicle registration,
he desires a fancy number in such a way that both the number
and its reverse are the same.
Generate an algorithm to find that fancy number.
Sample Input :
1221
Sample Output :
Number is Fancy

BEGIN
DECLARE variables number, reverse, rem, temp
READ number
SET reverse = 0, temp = number
WHILE number !=0 DO
number = number/10
rem = number%10
reverse = reverse*10 + rem
END WHILE
IF temp == reverse THEN
PRINT "Number is Fancy"
ELSE
PRINT "Number is Not Fancy"
END IF
END

BEGIN
DECLARE variables number, reverse, rem, temp
READ number
SET reverse = 0, temp = number
WHILE number !=0 DO
rem = number%10
reverse = reverse*10 + rem
number = number/10
END WHILE
IF temp == reverse THEN
PRINT "Number is Fancy"
ELSE
PRINT "Number is Not Fancy"
END IF
END

BEGIN
DECLARE variables number, reverse, rem, temp
READ number
WHILE number !=0 DO
SET reverse = 0, temp = number
rem = number%10
reverse = reverse*10 + rem
number = number/10
END WHILE
IF temp == reverse THEN
PRINT "Number is Fancy"
ELSE
PRINT "Number is Not Fancy"
END IF
END

Looping Statements-Check Your Understanding


1. Match the appropriate opening and closing blocks in looping
statements.

IF Answer 1 END IF

BEGIN Answer 2 END

WHILE Answer 3 END WHILE

FOR Answer 4 END FOR

2. Which looping logic is exit controlled?


Select one:
While loop
For loop
do-while loop
3. BEGIN
DECLARE variables i, factorial
SET factorial <-- 1
FOR i<--1 to 5 do
factorial <--factorial * i

i <-- i+1
END FOR
PRINT factorial
END
Which of the following statement should be inserted to complete
the above pseudo code for finding factorial of 5 numbers.

4. Consider the output: “0, 2, 4, 6, 8 ,10 ,12, 16”


Which of the below given pseudo code snippet gives the above
output?
Select one:
BEGIN
DECLARE number, count, even
SET count <-- 16, number <-- 0, even <-- 0
WHILE number<count
PRINT even
SET even <-- even + 2
Number <-- number+ 1
END WHILE
PRINT even
END
BEGIN
DECLARE number, count, even
SET count <-- 8, number <-- 0, even <-- 0
WHILE number<count
PRINT even
SET even <-- even + 2
number <-- number + 1
END WHILE
PRINT even
END
BEGIN
DECLARE number, count, even
SET count <-- 8, number <-- 0, even <-- 0
WHILE number<count
PRINT even
SET even <-- even + 1
Number <-- number+ 1
END WHILE
PRINT even
END

BEGIN
DECLARE number, count, even
SET count <-- 8, number <-- 0, even <-- 0
WHILE number<count
PRINT even
SET even <-- even + 2
Number <-- number+ 2
END WHILE
END

5. Predict the output of the given flowchart.

Select one:
2 2
2 1
1 1
1 2

6. Iteration/looping is a repetition of___________


Select one or more:
operation
Block of statements
variables
single statement
7. Do-while looping statement is almost same as______
Select one:
Nested if
While loop
for loop
if-else

8. What is true about FOR LOOP?


Select one:
For loop executes the statements at least once even if the
condition is false
In for loop, the exact number of iterations is known
For loop executes the statement without checking the condition
For loop cannot be nested

9. Jack wants to book flight tickets in Feather-Airways’ online


portal for his family of five. Passenger details like name, age,
gender etc. should be entered for each member. The same
process of getting details continues for all the five members. The
above scenario is a good example for which looping statements?
Do-while loop
For loop
While loop

10. What will be the output for WHILE loop?


BEGIN
DECLARE number
SET number <-- 30
WHILE number>0
number <-- number-4
END WHILE
PRINT number
END
Select one:
4
0
2
-2

11. What is the output for FOR-loop snippet?


FOR i <--1 to 15
PRINT i
i <-- i+3
END FOR Select one:
1 4 7 10 13
4 7 10 13 16
4 7 10 13
1 4 7 10 13 15 16

12. Which of the following symbols is inappropriate in building the


flowchart pertaining to sequential flow of program?
Select one:
oval
rectangle
diamond
parallelogram

13. The statement / statements within the loop must get executed
at least once except for do-while statement. State True/False.
Select one:
True
False

14. Which of the following statements are true with respect to


looping statements?
Select one or more:
the condition under which the iterative process should get
terminated must be given
initial condition must be applied before the loop begins to
execute
A loop should run infinite number of times
conditional statements are not allowed within a loop

15. Which of the following statements are true?


Select one or more:
The operand in an expression must always be a variable.
An operand is a mandatory element in an expression.
The operand in an expression must always be a constant.
The operand in an expression can be a variable or a
constant.

16. Consider you have a Rubik cube with different colors in each
face. To solve this cube, you will continue to rotate the sides until
you reach same colors in all faces. This is a real time example for
which looping statements?
Select one:
For
While
Nested-if
Do-while

17. DOWN:
1) Step by step list of instructions
4) When you know the exact number of iterations, this loop is
used
Across:
2)When a process/set of actions is to be repeated, these
statements are
used.
3) In looping, Each execution of a statement/block of
statements is
technically termed as______
5) This loop statement is also called as exit-controlled loop
18. Identify the logic which suits the flowchart?

Select one:
nested loop
Do-while loop
While loop
for loop

19. It's Halloween. You go from house to house, tricking or


treating. You get 2 candies from each house that you go to. You
must return home once you collect 100 candies. Can you arrange
the sequence for this loop activity.
1 BEGIN
2 SET candy count <- 0
3 END WHILE
4 DECLARE candy_count
5 WHILE candy_count<=100
6 candy count <- candy_count+2
7 END
1452367
1243657
1423657
1425637

20. Looping statements are also called ____________


Selection logic
Sequence logic
Program logic
Iteration logic

Arrays-Crack the puzzles


1. A farmer has 17 sheep and all but nine die. How many are left?
Select one:
8
17
9

2. In a year, there are 12 months. Seven months have 31 days.


How many months have 28 days?
Select one:
6
12
5
3. What is the next letter in the following sequence? J,F, M, A, M,
J, J, A, __.
Select one:
O
S
N

Pseudocode using Arrays – Quiz


1. Select the appropriate code snippet for the given problem
statement provided as pseudocode.
Problem Statement :
Dinner Plan
Five friends plan to go out for dinner. They plan to order equal
number of dishes. Each row specifies individual cost. Find the
total amount each person needs to pay.
Assume the values for this matrix for 3 dishes are
12 23 18
45 32 60
42 39 23
54 42 60
25 84 30
The output will be
Amount to be paid by person 1 is 53
Amount to be paid by person 2 is 137
Amount to be paid by person 3 is 104
Amount to be paid by person 4 is 156
Amount to be paid by person 3 is 139
Explanation : Output is the sum of each row

Code:
BEGIN
DECLARE variable arr[5][20], n, sum=0
___________________
FOR j IN 0 to n-1 DO
READ arr[i][j]
END FOR
END FOR
FOR i IN 0 TO 4 DO
SET sum = 0
FOR j IN 0 TO n-1 DO
sum = sum + arr[i][j]
END FOR
PRINT "Amount to be paid by person "+(i+1)+" is "+sum
END FOR
END
FOR i IN 0 to 3 DO
FOR i IN 0 to 4 DO
FOR i IN 0 to n DO
FOR i IN 0 to 5 DO

2. Choose the correct pseudocode for the below problem


statement.
Problem Statement :
Find Maximum value
Choose a pseudo code to find the maximum values in each row of
a matrix. Assume it is a 3x3 matrix.

Explanation : Matrix will be with index


(0,0) (0,1) (0,2)
(1,0) (1,1) (1,2)
(2,0) (2,1) (2,2)

Assume the values for this matrix are


12 23 18
45 32 60
42 39 23
The output will be
Max value in row 1 is 23
Max value in row 2 is 60
Max value in row 3 is 42
BEGIN
DECLARE variable arr[3][3]
FOR i IN 0 to 2 DO
FOR j IN 0 to 2 DO
END FOR
END FOR

FOR i IN 0 TO 2 DO
READ arr[i][j]
SET max = arr[i][0]
FOR j IN 0 TO 2 DO
IF arr[i][j]>max THEN
max = arr[i][j]
END IF
END FOR
PRINT "Max value in row "+(i+1)+" is "+max
END FOR
END

BEGIN
DECLARE variable arr[3][3]
FOR i IN 0 to 2 DO
FOR j IN 0 to 2 DO
READ arr[i][j]
END FOR
END FOR
FOR i IN 0 TO 2 DO
SET max = arr[i][0]
FOR j IN 0 TO 2 DO
IF arr[i][j]>max THEN
max = arr[i][j]
END IF
END FOR
END FOR
PRINT "Max value in row "+(i+1)+" is "+max
END

BEGIN
DECLARE variable arr[3][3]
FOR i IN 0 to 2 DO
FOR j IN 0 to 2 DO
READ arr[i][j]
END FOR
END FOR
FOR i IN 0 TO 2 DO
SET max = arr[i][0]
FOR j IN 0 TO 2 DO
IF arr[i][j]>max THEN
max = arr[i][j]
END IF
END FOR
PRINT "Max value in row "+(i+1)+" is "+max
END FOR
END

BEGIN
DECLARE variable arr[3][3]
FOR i IN 0 to 2 DO
FOR j IN 0 to 2 DO
READ arr[i][j]
END FOR
END FOR
SET max = arr[i][0]
FOR i IN 0 TO 2 DO
FOR j IN 0 TO 2 DO
IF arr[i][j]>max THEN
max = arr[i][j]
END IF
END FOR
PRINT "Max value in row "+(i+1)+" is "+max
END FOR
END

Arrays-Check Your Understanding


1. A mathematical quiz context happened in a school and the
scores are stored in an array named quizmark. The coordinating
person wants to copy the quiz score into another array named
copyquizmark. Which of these options will do that?
Select one:
We cannot copy the values from one array to another.
FOR index <- 0 to n
copyquizmark[index] <- quizmark[index]
index <- index+1
END FOR
copyquizmark[n] <- quizmark[n]
copyquizmark <- quizmark

2. Assume,
number[100] <- 99.
How many elements can be stored inside the array variable
number?
Select one:
99
100
The statement gives no clue about the number of elements
that can be stored
Infinite number of elements
3. Map the scenario to its appropriate array type
2D ARRAY
Matrix multiplication

1D ARRAY
To create a list of all prime numbers below 100

4. Which of the following are False with respect to the


manipulation of arrays?
Select one or more:
An array can store homogeneous data.
An array can store heterogeneous data
Elements of array are stored in contiguous memory
It is possible to increase the size of the array

5. Negative elements can be placed inside an array. State true /


false
Select one:
True
False

6. The names of all associates undergoing training are stored in


an array named associate_name[50]. The 5th associates’ name is
retrieved as
Select one or more:
associate_name[5]
associate_name[6]
associate_name[4]
associate_name[3+1]
7. Information about ___________ need not be specified when
declaring an array
Select one:
the data type of the array
the name of the array
the index of the array
the elements to be stored in the array

8. It is not possible to do a search operation in an array that is not


sorted. State True/False.
Select one:
True
False

9. Question text
The operation of ordering the elements in the list is known
as Sorting .

10. Random access is not possible in an array. State True/False


Select one:
True
False

11.Question text
Index
is used to locate an element in an array.
12. Assume you have an array named numbers of size 10.
Which of the assignment is valid?
Select one or more:
numbers[9] <- 5
numbers[11] <- 6
numbers[10] <- 11
numbers[0] <- 10

13. Which of the following statements is correct with respect to


arrays?
Select one:
Elements in an array are arranged in descending order by
default
Elements in an array are arranged contiguously.
Elements in an array are arranged in ascending order by
default

14. Question text


positive number
Expression within [ ] should always resolve to a

15. Consider you buy a laptop. You want to store the details of
that laptop such as price,
model_name,model_number, warranty_period into a single array
named details[10]. Is ths possible?
Select one:
Yes
No

16. Question text


List of songs stored in your mobile phone is a good example for
single-dimensional arrays

17. Consider you want to compare the prices of redmi , sony,


samsung phones in three online sites like amazon,flipkart,ebay.
Which array type is best suitable to do this comparision?
Select one:
one-dimensional array
two-dimensional arrays
three-dimensional arrays

18. It is possible to traverse through an array from the first


position to the last and not vice versa. State true or false.
True
False

19. An Array consists of rows and columns is also called


as________
Two-dimensional array
one-dimensional array
Three dimensional array

20. Choose the correct Pseudo code to store names in an array


and display a name.
BEGIN
INPUT name
DECLARE name [20]
END
PRINT name

BEGIN
INPUT name
DECLARE name [20]
PRINT name
END

BEGIN
INPUT name
PRINT name
DECLARE name [20]
END

BEGIN
DECLARE name [20]
INPUT name
PRINT name
END

Software Engineering Fundamentals-PreQuiz


1. ABC company comes to the Allen Software Company with
various requirement. The client wants the functionality to view all
the employee profile, view salary information of the employee and
view the leave details.Once each functionality is completed the
module will be delivered to the client. Which would be the right
model for this scenario. Select one:

Throwaway prototyping model


Spiral model
Incremental model
Scrum

2. A client wants to develop a Web application for the new Super


market store. The client want to have lot of UI components and
customers will have lot of interactions with the UI. What model is
best suited
Select one:
Prototype
Waterfall model
Spiral

3. ________ involves tranformation of user needs into an effective


software solution.
Select one:
Software Analysis
Software design process
Software development process
Software Testing

4. Spiral life cycle model is not suitable for products that are
vulnerable to large number of risks. State if True or False.
Select one:
FALSE
TRUE

5. When there is a difference between the output what is


expected and the actual one is termed as……
Select one:
Specification
Verification
Defect
Validation

6. XYZ Finance Co. has, at present, started its operations in India.


Based on the first six months performance, it has plans for
expansion across five countries. They want to automate their
operations at this stage. What is the process model that the
developer should choose to adopt?
Select one:
Spiral model
Evolutionary prototyping model
Waterfall model
Incremental model

Software Engineering Fundamentals-PostQuiz


1. Match the correct E,T,V,X (Entry,Task,Verify,Exit) criteria for the
below scenario

Reviewed design document Answer 1


Exit

Review of the artifacts Answer 2


Verfication
Developing HLD and LLD Artifacts Answer 3
Task

Input containing the reviewed SRS Answer 4


Entry

2. Scenario: LIC has manually carried out their process of premium


collection procedure for the past 45 years. Now, they have employed
the services of another company to automate the above.
Question: Which of the following models would you suggest to the
outsource company?
Select one:
Evolutionary prototyping
Spiral model
Waterfall model
Throwaway prototyping

3. Consider that you have to develop a flight control system. The


system is simulated as such that the original system is working. There
are many potential hazards with such a system. What model would
you suggest to develop the system?
Spiral model
Evolutionary prototyping
Throwaway prototyping
Waterfall model

4. Which model emphasizes Validation and Verification at each level


of stage containment?
Throwaway prototyping
V-Model
Spiral model
RAD
5. Testing performed by the user to ensure that the system meets the
agreed upon quality attributes and the specification is called as….
Select one:
Acceptance testing
System testing
Integration testing
Unit testing

6. Choose the option that accurately represents the sequential order


of phases in the Waterfall model.
Select one:
Requirement Gathering, Analysis, Design, Implementation,
Testing, Deployment, Maintenance
Requirement Gathering, Analysis, Design, Implementation,
Testing, Maintenance, Deployment
Requirement Gathering, Analysis, Design, Testing,
Implementation, Deployment, Maintenance
Analysis, Requirement Gathering, Design, Implementation,
Testing, Deployment, Maintenance

Software Engineering Fundamentals- Check


Your Understanding :
1. Which conforms that the software meets its technical
specifications?
Select one:
Design
Defect finding
Verification
Validation

2. The software is put into operation in the client’s environment.


The client comes back to enhance the UI to attract more
customers. This phase is called as _______________

Select one:
Development
Maintenance

3.Match the appropriate usage of the SDLC process models,


based on the nature of requirements
When the requirements are Answer 1
unclear Use the Throw aw ay prototype

When the requirements are Answer 2


unstable Use the Evolutionary prototype

4. Which of the below is one of the phase of the prototype model?


Quick design
Extensive testing
Detailed HLD phase
Detailed Coding
5.Match the phases of the Rapid Application Development model
against their objectives
Data Answer 1
modeling Information gathered from business modeling is used to define data objects

Process
modeling
Answer 2
Data objects are converted to achieve the business objective

Application
generation
Answer 3
Automated tools are used to convert process models into the actual system

Testing and Answer 4


turnover New components along w ith all the interfaces are tested

Business
modeling Answer 5
The information flow is identified betw een various modules

6. High-risk or major functions are addressed in the first cycles


there by delivering an operational product. Which of the SDLC
process models achieves this?
Select one:
Incremental model
Waterfall model
RAD model
Spiral Model
7. Beta technologies has undertaken a collision avoidance system
software to be implemented for airports. Additional safety
measures have to be automated by warning pilots when another
aircraft gets closer, otherwise impacts are huge. Which of the
following SDLC process models best suits the requirement?
Select one:
Waterfall model
V model
Spiral model
Evolutionary prototyping model

8. The student mark processing system software has been


developed and deployed at the St. Peters university. The system
shows the grade as 0 for all the students rather than the actual
grade. Which phase below was not done properly during the
SDLC?
Select one:
Software Analysis
Software Testing
Software Design
Software Maintenance

Phase of Software Engineering-PreQuiz


1. Aesthetics of the website is part of the functional requirement.
State true or false
Select one:
FALSE TRUE
2. _______ describes how the development activities will be
performed and how development phases follow each other.
Select one:
Software Development Process
Process
Design
Software Engineering

3. _________ is the application of a systematic, disciplined,


quantifiable approach to the design, development, operation and
maintenance of software.
Select one:
Software Engineering
Requirement Engineering
Software Testing

4. Requirement came to Allen Software company to develop a


software for military purpose. .00001 second delay in the missile
launching software would create greater loss to the human life.
What kind of model is best suited for this scenario?
Select one:
Agile
Spiral model
Waterfall model
Prototype

5. During which phase the following activities are performed:


Identifying the major modules of the system, how these modules
integrate, the architecture of the system and describing pseudo
code for each of the identified module
Select one:
Analysis
Maintenance
Design
Feasibility

Phase of Software Engineering-PostQuiz


1. Identify the possible entities from the given option
Select one or more:
Sale
Customer
SalesID
customerAge

2. Which of the following are available in SRS Document?


Select one or more:
Constraints
Functional Requirements
Non Functional Requirements
Design

3. What kind of non functional requirement best suit the below


scenario: Whenever the new offers are published in the online
shopping site, an sms has to be sent to all the registered
customers within 10 minutes of publishing
Select one:
Usability Requirement
Security Requirment
Portability Requirement
Performance Requirement

4.Choose the correct type of testing for the given Scenario

Testing to test the GUI components in the screen Answer 1


Usability Testing

Testing to check if the report is generated within 5 Answer 2


sec on click of the button as agreed in the SRS Performance Testing

Testing to check if 1000000 users accessing Answer 3


website at the same point of time Load Testing

Testing to check if the card is swiped for more than


three times with wrong pin, the card has to be Answer 4
Security Testing
blocked

5. Whenever a new product is arrived, the stock needs to be


updated. This requirement is an example for non functional
requirement. State true or False
FALSE
TRUE

6. Consider the below scenario. A team has many players and the
player belongs to one team. Identify the cardinality between
player and team
1:M
1:1
M:1
M:M
Phase of Software Engineering- Check Your
Understanding :
1. Which of the following options are the steps involved in
Requirements Analysis?
Select one or more:
Analysis of the gathered requirements
Requirements Specification
Requirements Elicitation
Requirements Gathering

2. From the below options, identify the role of the system analyst.
Writes pseudo code for the given module
Creates high level test cases
Creates HLD document
Creates SRS

3. Identify the correct statements from the below options.


High level design, Low level design followed by Analysis is
performed.
Analysis is performed followed by High level design and
then Low level design
Analysis is performed followed by low level design and then
high level design
Analysis or High level design or Low level design can be
performed in any order
4. Match the correct objectives of each phase involved in
Requirements Engineering
Requireme
nts
Analysis
Answer 1
Analyzing the customer and the user/stakeholder to arrive at a definition of softw are requirements

Requireme
nts Answer 2
Documents all the requirements properly
Specificatio
n
Requireme
nts
Elicitation Answer 3
Gathering requirements from the users, customers and other stake holders

5. Identify the type of design that helps in transforming the data


model created during requirements analysis phase into the data
structures that will be used to implement the software
Select one:
Data Design
Interface design
GUI Design
Architectural design

6. Match the objectives of the types of design involved


Low Answer 1
Level Focuses on w riting a detailed algorithm

Design
Architect
ure
design Answer 2
Defines the modules of the system and the functions that each module perform

Interface Answer 3
design Describes how the softw are communicates w ith itself, and w ith the users interacting w ith the softw are

Phase of Software Engineering- Crack the


Puzzles

1. What does come down but never goes up? _______


What can one catch that is not thrown? _______
What goes up and down, but always remains in the same place?
_______
what word that changes a girl into a woman? _______

Choose the correct answer:


Cold, Rain, Stairs, Age
Age, Rain, Stairs, Cold
Stairs, Cold, Stairs, Age
Rain, Cold, Stairs, Age

2. You are in a race and overtake the person who is in second


place. What place are you now in?
Select one:
First
Second
Third

3. A lady buys goods worth Rs.200 from a shop. (shopkeeper is


selling the goods with zero profit). The lady gives him Rs.1000
note. The shopkeeper gets the change from the next shop and
keeps Rs.200 for himself and returns Rs.800 to the lady. Later the
shopkeeper of the next shop comes with the Rs.1000 note saying
“duplicate” and takes his money back.

How much LOSS did the shopkeeper face?


Select one:
1000
800
2000
200
Software Testing-PreQuiz
1. An SRS has the following requirement.The stock exchange
shall show the stock report for the next 24 hours.What is the issue
with this requirement
Select one:
Inconsistent
Ambiguous
Requirement is Correct
In correct

2. Client Comes to Allen Company for a Banking Solution.Which


phase of SDLC is best suited to gather what is expected from
client
Select one:
Feasibility Analysis
Requirement analysis
Customer Analysis
System Analysis

3. The standard document that describes all the requirements of


the system is called as …
Select one:
User Requirement Specification
Software Requirement Specification
Test Case Document
Contract Document

4. In remote control Car application, in the step by step execution


of the requirement described, it is mentioned when the fuel level
goes below the minimum level, the application should indicate the
user in red color. In the output section of the same process it is
mentioned that the indicator will glow pink. What is the kind of
requirement specified in SRS?
Select one:
Incomplete
Contradicting
Complete
Consistent

5. A good SRS should be ______, ________ and _______.


Select one or more:
Traceable
Complete
Periodical
Consistent

6. Client Comes to Allen Company for a Banking Solution. Who


from the below options would be best suited to gather all the
requirements correctly from the client
Select one:
Analyzer
Database Analyst
System analyst
System Architect
Software Testing-PostQuiz
1. In the online shopping portal, for customer registration the
password field can accept only characters in the range of 5 to 25.
Derive test cases using Boundary value analysis
Select one:
6,24,10,25
5,25,26,3
5,25,4,26
5,25,6,24

2. The testing technique that deals with the internal logic and
structure of the code is called ________.
Select one:
Pure Box Testing
Logical Testing
WhiteBox Testing

3. Determine the cyclomatic complexity for the following code:

Accept year
if(year mod 4=0 and year mod 100!=0) or(year mod 400 =0)
print year is leap
else
print year is not leap
end if.
Select one:
4
6
5
3

4. Walk through is performed by the trained moderator, whereas


the Inspection is usually conducted by the author itself to record
defects and deviations
Select one:
True
False

5. After implementation of Library management system, the tester


identified that certain logic are redundantly rewritten by the
developers, and the coding standards are violated in few
modules. What type of testing is carried out to identify these
errors?
dynamic testing
debugging
Static Testing
error guessing

6. Tester is trying to test whether the values in the drop down are
listed properly.
What type of testing the tester performs in this scenario?
Acceptance Testing
Regression Testing
Black box testing
White box Testing
7. Boundary value analysis can only be used during white-box
testing. State if True or False.
Select one:
FALSE
TRUE

Software Testing- Check Your Understanding


1. Identify this technique of dynamic testing where, For a range of
input, three values are chosen, One value above the range, One
value below the range, and One value within the range
Select one:
Cause Effect Graphing
Error Guessing
Boundary Value Analysis
Cause Effect Analysis
Equivalence partitioning

2. What is the difference between the actual output of a software


and the correct output?
Select one:
Bug
Error
Fault
Defect

3. Match the objectives of the phases of Software Testing Life


Cycle

Test Answer 1
Execution Executing test scripts and Finding bugs

Test
Design Answer 2
Test scenarios, test cases, test data, and test scripts are prepared

Test Plan
Answer 3
Resource allocation, creation of test environment, test schedule and test functionality

4. Match the roles involved in Static Testing


Inspector Answer 1 Inspecting the document

Moderator Answer 2 Leads the review process

Author
Writer of the ‘document under review ’
Answer 3

Scribe Answer 4 Records each defect found

Reader Presents the document


Answer 5

5. What is the type of testing in which the tester will know about
the input and the expected output details based on the
specification document only but no knowledge on
implementation?
Select one:
Regression Testing
Black Box Testing
Integration Testing
Usability Testing
White Box Testing

6. Identify the correct phases of software testing life cycle.


Requirements Analysis,Test Preparation,Test Case
development,Test Environment Set up,Test Execution,Test
Cycle closure
Requirements Analysis,Test Preparation,Test Case
development,Test Execution,Test Environment Set up,Test Cycle
closure
Requirements Analysis,Test Preparation,Test Case
development,Test Environment Set up,Test Cycle closure,Test
Execution
Requirements Analysis,Test Case development,Test
Preparation,Test Environment Set up,Test Execution,Test Cycle
closure

7. Match the objectives against the techniques of generating test


cases in black box testing

State
Transition Answer 1
Involves actions as one of its components
Diagram

Cause
Effect Answer 2
The causes and effects represent the nodes
Graphing
Cause
Effect Answer 3
It is suitable for applications in w hich combinations of input conditions are few
Analysis

8. Which all of the following options would basis path testing


perform?
Select one or more:
Statement Coverage
Loop Coverage
Condition or Branch Coverage
Test Case Coverage

Software Configuration Management-Pre-Quiz


1. Y2K problem is an example for ------------- maintenance
Select one:
Preventive
Adaptive
Perfective
Corrective

2. Software maintenance for the change of the platform is an


example for --------- maintenance
Select one:
Adaptive
Perfective
Preventive
Corrective
3. Client wanted to add a new feature to his existing application
"Discount Offers" for all the existing customers. Whenever a new
product comes to the supermarket, their customer's should be
intimated with the week day offer. What kind of maintenance is
this?
Select one:
Adaptive Maintanence
Perfective Maintanence
Corrective Maintanence
Preventive Maintanence

4. In Software maintenance, changes are implemented by


modifying existing components and adding new components to
the system. State if True or False.
Select one:
True
False

5. Any changes done to the software during the operational phase


of the software before project wind up is called as maintenance.
State if True or False.
Select one:
TRUE
FALSE

6. In an online shopping application, during customer registration


the customer was made to enter his city in a text box. As the site
became popular for online shopping, the client came back to
include autocomplete feature in the city field to improve user
friendliness. What maintenance needs to be carried out in this
scenario?
Select one:
Corrective
Adaptive
Perfective
Preventive

7. Client has developed an application that allows each of their


customers to store 2TB of data. As the number of Customers are
increasing client feels the storage space has to be increased for
smooth operations to its customers. What type of maintanence is
this?
Select one:
Preventive Maintanence
Adaptive Maintanence
Corrective Maintanence
Perfective Maintanence

Software Configuration Management-PostQuiz


1. From the options identify the features that are part of the
software configuration management
Select one or more:
Concurrency control
Support management
Version management
Synchronisation control

2. Match the correct option


The standard document where the requester
fills the change in the change management Answer 1
Change Request Form
process
Who authenticates that the change proposed Answer 2
is valid Change Control Board

Process that ensures that changes made are Answer 3


recorded and controlled Change Management

Process that ensures different versions of the Answer 4


project is managed Configuration Management

3. _________ is a committee that makes decisions regarding


whether or not proposed changes to a software project can be
incorporated.
Select one:
Modify Control Board
Change Control Board
Decision Committee
Updation Control Board

4. Which of the following describes the change history of an


object?
Select one:
Review Graph
Evolution graph
Check-out
Baseline

5.Question text
SRS version artifact baseline
The entry door of the Server room inside the company can be
baseline
considered as equivalent to concept in configuration
management.

6. State true or false. Automated tools are available in the market,


for managing change and versioning the software
Select one:
TRUE
FALSE

7. Question text

Preventive Perfective Corrective Adaptive


John bought a new Laptop with a high end configuration. To
protect his laptop and the applications installed he installed a
antivirus software.This is an example for Preventive Maintenance

8. Version Management allows parallel concurrent development.


State True or False.
Select one:
True
False
Software Configuration Management- Check
Your Understanding :
1. Which of the following options are valid for the relationship
between the configuration objects?
Select one or more:
A double-headed straight arrow indicates an
interrelationship
A curved arrow indicates an interrelationship
A double-headed straight arrow indicates compositional
relation
A curved arrow indicates a compositional relation

2. Match the following facts about Version Management


When a member of the team wants his
code to work in isolation Answer 1
Create branches

Lock a file Answer 2


Serialized changes to file.

If a file is changed and we want to roll back


to the previous version
Answer 3
Automatic backup

3.Question text: Configuration audit Configuration


Management Version Control ChangeManagement
Configuration audit
is responsible for reviewing the items against various
specifications for assessing its quality and correctness.

4. Version Control allows users to lock files so they can only be


edited by one person at a time and track changes to files
Select one:
True
False

5. Choose the missing steps involved in the Change Control


Process in the correct order:
1. Identify and submit change request
2. ____________
3. Plan the change
4. Implement and test the change
5. Verify implementation of change
6. Close change request

Select one:
Review stakeholder feedback
Analyze the cost of the proposed change
Collect impacts of change request
Evaluate impacts of change request

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy