C examples for String:String Function
Change character case with functions strlwr() and strupr().
#include <stdio.h> #include <string.h> int main( void ) { char buf[80]; while (1)//w w w . ja v a2 s.c o m { puts("Enter a line of text, a blank to exit."); gets_s(buf); if ( strlen(buf) == 0 ) break; puts(strlwr(buf)); puts(strupr(buf)); } return 0; }