float
double
long double
far double
What is the output of the following code?
int arr[5] = {1, 2, 3, 4, 5};printf("%d", arr[3]);
1
2
3
4
int arr[10][10];
int arr[10,10];
array int arr[10][10];
int arr{10}{10};
is executed only once if the conditions is true
is also known as entry-controlled loop
is executed at least once if the conditions is false
the unconditional loop
0
Infinitely
Variable
Consider the following code and How many bytes of memory will be allocated?
int *ptr = (int *)malloc(10 * sizeof(int));
10 bytes
20 bytes
80 bytes
40 bytes
auto
case
main
default
Compiler
Interpreter
Assembler
None of These
It exits the current loop and continues with the next iteration
It terminates the current loop and transfers control to the next statement after the loop
It skips the current iteration and moves to the next iteration
It repeats the current iteration
is executed only once if the condition is true.
is also known as entry-controlled loop.
is executed at least once if the condition is false.
is unconditional looping statement..
* / % + - =
= * / % + -
/ * % - + =
* % / - + =
switch
goto
go back
return
ceil(1.66)
floor(1.66)
roundup(1.66)
roundto(1.66)
it Compare the variable a and the variable b are same.
The value of b is assigned to variable a but if b changes later, it will not effect the value of variable a.
The value of b is assigned to variable a but if b changes later, it will effect the value of variable a.
The value of variable a is assigned to variable b, and the value of variable b is assigned to variable a.
power of y to the x
power of x to the y
logarithm of x on the base y
Such function does not exist
world
addition23
test-name
factorial
Constants
Keywords
Operators
Tokens
To exit the function and return control to the calling function
To pause the function temporarily
To call the function again
To exit the program
arr[2]
arr(2)
arr[3]
arr[1]
int my_num = 100,000;
int my_num = 100000;
int my num = 1000;
int $my_num = 10000;
scanf()
getch()
getche()
gets()
Binary operator
Unary operator
Ternary operator
All of the above
_infomax
3infomax
infomax_ica
infomax123
In the following nested conditional statements, which branch will execute?
int x = 4;if (x > 2) { if (x < 5) { printf("x is between 2 and 5"); }} else { printf("x is 2 or less");}
x is between 2 and 5
x is 2 or less
Error
No output
-1
do-while
if-else
for
while
LowerCase letters
UpperCase letters
CamelCase letters
None of these
put together the file and functions that are required by the program
translate the instructions into a form suitable for execution by the program
load the executable code into the memory and execute them
allow the user to type the program
Algorithm
Flow-Charts
Procedural
Object Oriented
Logical Operator
Conditional Operator
typecast
Ternary
*
+
++
&&
Read
Write
Execute
Copy
Either True or False
is less than or is more than
is equal or less or more
Value of elements in array
First element of the array
Base address of the array
Address of the last element of array
"r"
"w"
"rw"
"read"
Keywords can be used as variable names
Variable names can contain digits
Variable names do not contain blank spaces
Capital letters can be used in variable names.
What will be output if you will compile and execute the following c code?
int main(){ int a=5; float b; printf("%d",sizeof(++a+b)); printf(" %d",a); return 0;}
2 6
4 6
2 5
4 5
5
6
Undefined
void
endl
ctype.h
stdio.h
conio.h
math.h
printf("\n");
echo '\n';
printf('\n');
printf('\\n')
char
array
print("Hello World");
echo("Hello World");
printf("Hello World");
To determine which operator evaluated first from left to right.
To determine the level of an operator in a program.
To determine how an expression involving more than one operator is evaluated.
To check the expression is valid or not.
no of students
7th
myName
Find the output of following code :
int main() { int i=-2; printf (“-i=%d”,-i); return b; }
–i=2
i=-2
–i=-2
–i=+2
Id_No
ID_NO
IdNo
Id No
How many times will the following loop execute?
int j;for(j = 1; j <= 10; j = j-1)printf("INFOMAX");
Forever
Never
10
static
new
volatile
When the following piece of code is executed, what happens?
b = 3;a = b++;
a contains 3 and b contains 4
a contains 4 and b contains 4
a contains 4 and b contains 3
a contains 3 and b contains 3