1.

What is the output of this program?
#include <iostream> 
#include <ctype.h>
int main ()
{
int k = 0;
char str[] = "Ajit Kumar Gupta";
char ch;
while (str[k])
{
ch = str[k];
if (islower(ch))
ch = toupper(ch);
putchar (ch);
k++;
}
return 0;
}

A. AJIT KUMAR GUPTA
B. Ajit Kumar Gupta
C. Compilation Error
D. Runtime Error
E. None of these
Answer» B. Ajit Kumar Gupta


Discussion

No Comment Found

Related MCQs