fork download
  1. #include <stdio.h>
  2.  
  3. int main(void) {
  4. // your code goes here
  5. int x;
  6. printf("Enter a number: ");
  7. scanf("%d",&x);
  8. if(x%5==0){
  9. if(x%3==0){
  10. printf("The number is divisible by 5 and 3");
  11. }
  12. else{
  13. printf("The number is not divisible by 5 and 3");
  14. }
  15. }
  16. else{
  17. printf("The number is not divisible by 5 and 3");
  18. }
  19. return 0;
  20. }
  21.  
Success #stdin #stdout 0s 5288KB
stdin
Standard input is empty
stdout
Enter a number: The number is not divisible by 5 and 3