daily pastebin goal
26%
SHARE
TWEET

Untitled

a guest Oct 20th, 2018 60 Never
Upgrade to PRO!
ENDING IN00days00hours00mins00secs
  1. #include <stdio.h>
  2.  
  3. char * codifica (char *str);
  4.  
  5. int main()
  6. {
  7.     char chain[30];
  8.     scanf(" %29[^\n]",chain);
  9.     int k;
  10.     for(k=0;chain[k]!='\0';k++);
  11.     char*resp;
  12.     resp=(char*)malloc(sizeof(char)*k);
  13.     resp=codifica(chain);
  14.     for(int i=0;i<k;i++)printf("%c",resp[i]);
  15.    
  16.     return 0;
  17. }
  18.  
  19. char * codifica (char *str){
  20.     for(int i=0;str[i]!='\0';i++){
  21.         if(str[i]==97||str[i]==101)str[i]='?';
  22.         else if(str[i]==105||str[i]==111||str[i]==117)str[i]='?';
  23.     }
  24.     return str;
  25. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top