Advertisement
Guest User

Untitled

a guest
Feb 25th, 2020
89
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.20 KB | None | 0 0
  1. #include<iostream>
  2. #include<fstream>
  3. using namespace std;
  4. int main()
  5. {int a,ok=0;
  6. ifstream f("numere.in.txt");
  7. while(f>>a)
  8. {if((a-1)%3==0)
  9. {cout<<a<<" ";
  10. ok++;}}
  11. if(ok==0)
  12. cout<<"Nu exista";}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement