Pseudo Code
Pseudo Code
1. How should we present the statement language while writing a pseudo code?
a) Dependent
b) Independent
c) Case Sensitive
d) Capitalized
Ans:- Independent
2. We should capitalize initial keyword while writing the pseudocode___ This is a rule.
a) True
b) False
c) Depends on code
d) Depends on your wish
Ans:- True
Ans:- Start
Ans :- Indentation
5. Which of the following options tells the computer to get a value from an input device
and store it in a memory location?
a) Read
b) Write
c) READ
d) WRITE
Ans:- READ
6. Which of the following options is identified by their addresses, we give them names
(field names / variable names) using words.
a) Memory variables
b) Memory Locations
c) Memory Addresses
d) Data Variables
7. With respect to the rules of pseudocode, Which of the following options begins with
lower case letters.
a) Keywords
Ans Variables
Ans **
Ans ()
Ans ENDIF
Ans:- -3049
2. Below is a pseudo-code
Set x = 0;
Set y = 1;
Set n = 0
print(8)
print(1)
Ans 0
10. What will be the output of the following pseudocode for the given set of input?
#include <stdio.h>
void main()
int a = 1.0, b = 2, c = 3.12;
char d = 0.0;
if (a, b, c, d)
{
printf("KHUDSOLVEKRO");
}
}
a. No output
b. Error
c. KHUDSOLVEKRO
d. 1.0
Ans No output
Ans %x
2. Observe the code carefully and choose the correct output of this code.
#include <stdio.h>
int main()
{
typedef int score;
score result = 0.00;
printf("%d", result);
return 0;
}
a. 0.0
b. 0.00
c. 0.000000
d. 0(Zero)
Ans: 0(Zero)
3. Observe the code carefully and choose the correct output of this code.
#include <stdio.h>
int main(){
float m = 0.0;
long int n = 10;
printf("%d", sizeof(m) == sizeof(m+n));
return 0;
}
a. 10
b. 10.0
c. 10+0.0
d. 0(Zero)
Ans:- 0(Zero)
Ans:- 320
5. Observe the code carefully and choose the correct output of this code.
#include <stdio.h>
int main()
{
int tell = 5.0, scl =1*10;
do {
scl /= tell;
} while(tell--);
printf ("%d\n", scl);
return 0;
}
a. Floating-point exception
b. 10
c. 5.0
d. 10.0
Ans 1
Ans 0.000000