Advertisement
fiqriachmada

IkaEjaanLamaPraktikumIII

Dec 11th, 2018
179
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.67 KB | None | 0 0
  1. #include <iostream>
  2. #include <stdio.h>
  3. #include <string.h>
  4.  
  5. using namespace std;
  6.  
  7. int main(){
  8.     char kata[100], kata2[100];
  9.     cout<<"input            : ";
  10.     gets(kata);
  11.     strcpy(kata2, strlwr(kata));
  12.     cout<<"Ejaan Lama       : ";
  13.     for(int i=0;i<strlen(kata2);i++){
  14.         if(kata2[i]=='u'){
  15.             cout<<"oe";
  16.         }
  17.         else if(kata2[i]=='j'){
  18.             cout<<"dj";
  19.         }
  20.         else if(kata2[i]=='y'){
  21.             cout<<"j";
  22.         }
  23.  
  24.         else if(kata2[i]=='c'){
  25.             cout<<"tj";
  26.         }
  27.  
  28.         else{
  29.             cout<<kata2[i];
  30.         }
  31.     }
  32.     cout<<"\nEYD              : ";
  33.     cout<<strlwr(kata);
  34. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement