Thursday, February 14, 2008

Aptitude Question No.5

Aptitude Question No.5

enum colors {BLACK,BLUE,GREEN}
main()
{
printf("%d..%d..%d",BLACK,BLUE,GREEN);
return(1);
}
Answer
0..1..2

Explanation
enum assigns numbers starting from 0, if not explicitly defined

No comments:

2008 Placement papers of Top MNC companies

eXTReMe Tracker