Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <stdio.h>
- #include <stdlib.h>
- int main(){
- char c;
- char t[100];
- int i=0;
- int szam1;
- int szam2;
- do {
- scanf("%c", &t[i]);
- if(t[i]==64)
- break;
- i++;
- } while(1 );
- /*while(1){
- t[i]=scanf("%c", &c);
- if(c==64)
- break;
- i++;
- }*/
- printf("\n\n");
- printf("Adj meg ket szamot: ");
- printf("\n\n");
- scanf("%d", &szam1);
- scanf("%d", &szam2);
- //if(szam1<=szam2)
- //if(szam1 <= strlen(t)-1 && szam2<=strlen(t)-1)
- for(i=szam1; i<=szam2; i++){
- printf("%c", t[i]);
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement