Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <string.h>
- void Cap(char string[]){
- int i;
- int x = strlen(string);
- for (i=1;i<x;i++){
- if (isalpha(string[i]) && string[i-1] == ' '){
- string[i]= toupper(string[i]);
- }
- }
- }
- main(){
- char string[] = "texto en minuscula.";
- Cap(string);
- printf("%s",string);
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement