Advertisement
Guest User

Untitled

a guest
Oct 22nd, 2019
105
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7. int N;
  8. cin>>N;
  9. if ((N%2==0) && (N%3==0)){
  10. cout<<"fizzbuzz";}
  11. else{
  12. if (N%2==0){
  13. cout<<"fizz";}
  14. else
  15. if(N%3==0){
  16. cout<<"buzz";}}
  17. return 0;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement