adplus-dvertising
frame-decoration

Question

What is the output of C program?
int main() 
{ 
float marks[3] = {90.5, 92.5, 96.5}; 
int a=0; 
while(a<3) 
{ 
printf("%.2f,", marks[a]); 
a++;
 } 
}

a.

90.5 92.5 96.5

b.

90.50 92.50 96.50

c.

0.00 0.00 0.00

d.

Compiler error

Posted under C Programming

Answer: (b).90.50 92.50 96.50

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. What is the output of C program?

Similar Questions

Discover Related MCQs

Q. What is an array Base Address in C language?

Q. An entire array is always passed by ___ to a called function.

Q. What is the value of an array element which is not initialized?

Q. What happens when you try to access an Array variable outside its Size?

Q. Can we change the starting index of an array from 0 to 1 in any way?

Q. What is the need for C arrays?

Q. What is a multidimensional array in C Language?

Q. If an integer array pointeris incremented, how many bytes will be skipped to reach next element location?

Q. What is the function used to allocate memory to an array at run time with Zero initial value to each?

Q. What is the function used to allocate memory to an array at run time without initializing array elements?

Q. Choose a correct Syntax for malloc() function to allocate memory to an array at run time.

Q. What is the syntax of CALLOC to allocate memory to an array at runtime.?

Q. What is the dimension of the C array int ary[10][5]?

Q. Choose a correct statement with array pointers.

Q. Choose correct statement about C array pointers.

Q. Difference between C Arrays, ary[10] and cry[10][10] is

Q. Array of Arrays is also called

Q. Choose a correct statement about a C Multidimensional array.

Q. A multidimensional array of dimension N is a collection of

Q. Choose a correct statement about a Multidimensional array and pointer.