Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if(scanf("%d",&x1)!=1)
- {
- printf("Incorrect input");
- return 1;
- }
- printf("Podaj x2: ");
- if(scanf("%d",&x2)!=1)
- {
- printf("Incorrect input");
- return 1;
- }
- if(x1>x2)
- {
- printf("Incorrect input");
- return 1;
- }
- if(x1==x2)
- {
- printf("Nothing to show");
- return 0;
- }
- for(i=x1;i<=x2;i++)
- {
- if(is_twin(i,i+2)==1&&(i+2)<=x2)
- {
- printf("%d %d\n",i,i+2);
- licznik++;
- }
- }
- if(k==0)
- {
- printf("Nothing to show");
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement