Advertisement
catalyn

tot 25.09.2014

Sep 25th, 2014
259
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.25 KB | None | 0 0
  1. #include <fstream>
  2.  
  3. using namespace std;
  4. ifstream f("date.in");
  5. ofstream g("date.out");
  6. int main()
  7. {
  8. int n,i,j;
  9. f>>n;
  10.  
  11. for(i=1;i<=n;i=i+2)
  12. for(j=n;j>=1;j--)
  13. if(i+j==n and i%2==1 and j%2==1)
  14. g<<i<<" "<<j<<" ";
  15. return 0;
  16.  
  17. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement