#include <stdio.h>
#include <stdlib.h>
int main(){
printf("Program Membalikkan Kalimat\n");
char a[6] ={'M','A','L','A','N','G'};
printf("Nama Semula : ");
for(int y=0; y<6; y++){
printf("%c",a[y]);
}
printf("\n");
printf("Kebalikan : ");
for (int i=5;i>=0;i--){
printf("%c",a[i]);
}
printf("\n\n");
char b[7] ={'M','A','K','A','S','I','H'};
printf("");
for(int w=0; w<7; w++){
printf("%c",b[w]);
}
printf("\n");
printf("");
for (int z=6;z>=0;z--){
printf("%c",b[z]);
}
printf("\n\n");
system("PAUSE");
return(0);
}
0 komentar:
Posting Komentar