Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include<stdio.h>
- main(){
- char vet[10];
- int mod;
- printf (" Digite a palavra a ser codificada: \t");
- gets (vet);
- for(mod=0; mod<10; mod++){
- printf(" %c",vet[mod]+1);
- vet[0]=vet[0]+(9);
- vet[1]=vet[1]+(8);
- vet[2]=vet[2]+(7);
- vet[3]=vet[3]+(6);
- vet[4]=vet[4]+(5);
- vet[5]=vet[5]-(4);
- vet[6]=vet[6]-(3);
- vet[7]=vet[7]-(2);
- vet[8]=vet[8]-(1);
- vet[9]=vet[9]-(6);
- }
- printf("\n");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement