213k views
2 votes
The _________ function returns the uppercase equivalent of its character argument.

A) toupper()
B) tolower()
C) isupper()
D) strupr()

User Modelnine
by
8.6k points

1 Answer

1 vote

Final answer:

option a,The toupper() function returns the uppercase equivalent of its character argument.

Step-by-step explanation:

The toupper() function in C returns the uppercase equivalent of its character argument. This function takes a single character as input and converts it to uppercase. For example, if you pass the character 'a' to the toupper() function, it will return 'A'.

Here's an example of using the toupper() function in C:

#include <stdio.h>
#include <ctype.h>

int main() {
char c = 'a';
char upperC = toupper(c);
printf("%c", upperC);
return 0;
}

This code will output 'A'.

User CHANist
by
7.4k points