[Updated] Goldman Sachs Aptitude Test Questions and Answers
Practice List of TCS Digital Coding Questions !!!
Take 50+ FREE!! Online Data Interpretation Mock test to crack any Exams.

C Programming :: Control Instructions - Discussion

Home > C Programming > Control Instructions > MCQs Questions Discussion

4 / 33

What is the output of the following 'C' program?

#include<stdio.h>
void main() 
{
float i=1.5;
switch(i)
{
case 1: printf("1"); 
case 2: printf("2"); 
default : printf("0");
}
}

A1 2 0

B2

CCompiler error: switch quantity not an integer

D1

ENone of these

Answer: Option (Login/Signup)

Show Explanation

Asked In :: Societe Generale

Post Your Answer Here:     

Reply    
Rate This: +0 -0
    Report


Report Error

Please Login First Click Here