Kod: Zaznacz cały
#include <stdio.h>
#include <cctype>
#include<string.h>
int main()
{
int i;
char napis[ 30 ];
while (strcmp(napis,"koniec")!=0)
{
printf("Podaj tekst: ");
fgets(napis, sizeof(napis), stdin);
for( i = 0; i <= 30; i++ )
{
if( isalpha( napis[ i ] ) )
napis[ i ] += 1;
}
napis[i]=NULL;
if(strcmp(napis,"koniec")!=0)
{
printf("%s
", napis);
}
}
return 0;
}