Strings
- What will be the output of the following C code?
#include <stdio.h>
#include <ctype.h>
int main()
{
int num = 15;
if (isspace(num))
{
printf("Space\n");
}
else
{
printf("Not Space\n");
}
return 0;
}
-
View Hint View Answer Discuss in Forum
NA
Correct Option: C
Not Space
- What will be the output of the following C code?
#include <stdio.h>
#include <ctype.h>
int main()
{
int n = ' ';
if (isspace(n))
{
printf("Space\n");
}
else
{
printf("Not Space\n");
}
return 0;
}
-
View Hint View Answer Discuss in Forum
NA
Correct Option: B
Space
- Which is true about isaplpha(ch), where ch is an int that can be represented as an unsigned?
char or EOF.isalpha(ch) returns
-
View Hint View Answer Discuss in Forum
NA
Correct Option: C
Both 0 if ch is not alphabetic & Non-zero if ch is alphabetic
- Which is true about isupper(ch), where ch is an int that can be represented as an unsigned?
char or EOF.isupper(ch) returns
-
View Hint View Answer Discuss in Forum
NA
Correct Option: C
Both 0 if ch is not upper case & Non-zero if ch is upper case
- Which is true about isalnum(ch), where ch is an int that can be represented as an unsigned?
char or EOF.isalnum(ch) returns
-
View Hint View Answer Discuss in Forum
NA
Correct Option: D
Both 0 if not isalpha(ch) or not isdigit(ch) & Non-zero if isalpha(ch) or isdigit(ch)