In general a function reference would be written as
putchar(character variable)
where character variable refers to some previously mentioned character variable.
Below is a simple example which takes a character as input from the user and displays the equivalent uppercase character.
/*lowercase to uppercase conversion*/
#include
#include
main()
{
char ch;
printf("Enter any character value");
ch=getchar();
printf("The equivalent uppercase character is ");
putchar(toupper(ch));
}
No comments:
Post a Comment