Advertisement
Guest User

Untitled

a guest
Nov 22nd, 2017
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.42 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7. int x2, x3, n, n1;
  8. cin>>n;
  9. x3 = n / 3;
  10. n = n % 3;
  11. if ((x3 == 1) && (n = 1))
  12. {
  13. cout<<2<<" "<<2;
  14. }
  15.  
  16.  
  17. if (n == 0)
  18. cout<<3<<" "<<x3<<endl;
  19. else
  20. if ((n % 2) == 0)
  21. cout<<3<<" "<<x3<<" "<<n/2<<endl;
  22. else
  23. cout<<2<<" "<<2<<" "<<3<<" "<<(x3 - 1)<<endl;
  24. return 0;
  25. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement