Advertisement
adnit

Untitled

Dec 7th, 2019
139
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.69 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main()
  5. {
  6.  
  7. int n;
  8. cout << "Shtyp numrin : " << endl;
  9. cin >> n;
  10.  
  11. switch (n % 2)
  12. {
  13. case 0:
  14. if (n == 2)
  15. {
  16. cout << "Numer i thjeshte";
  17. }
  18. else
  19. cout << "Numer jo i thjeshte";
  20. break;
  21. case 1:
  22. if (n % 3 == 0)
  23. {
  24. cout << "Numer jo i thjeshte";
  25. }
  26. else if (n % 5 == 5)
  27. {
  28. cout << "Numer jo i thjeshte";
  29. }
  30. else
  31.  
  32. {
  33. cout << "Numer i thjeshte";
  34. }
  35. break;
  36. default:
  37. cout << "Default";
  38. break;
  39. }
  40.  
  41. return 0;
  42. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement