void main(){ int i,j; scanf("%d",&i); if((i%5)==0) printf("the given number is divisible by 5); }
To check for divisibility, use the modulus, or % operator. If the expression results in zero, then the first number is divisible by the second number. For example, 10%5 equals 0 because 10 is divisible by 5. When the expression does not result in 0, the number is not divisible(10%7=3, so 10 is not divisible by 7).
12345 1234 123 12 1
Using while loop, write a program which calculates the product of digits from 1 to 5 and also show these no's vertically.
Write a program which takes the temperature in farhenheight.the program should display the farhenheight temperature as well as centigrade. C= (f-32)*5/9
#! /usr/bin/env rubyn = gets.to_id = 'is not'd = 'is' if n % 7 == 0puts 'Your number ' + d + ' divisible by seven.'For more accurate answer, please define the programming/script language you plan to use..
2390 is not divisible by 3 but is divisible by 5. 2 + 3 + 9 + 0 = 14; 1 + 4 = 5: 5 is not divisible by 3, so 14 is not divisible by 3, so 2390 is not divisible by 3. 2390 ends with a 0, so 2390 is divisible by 5.
A number that is divisible by 15 is divisible both by 5 and 3 A number is divisible by 5 if it ends with 0 or 5 A number is divisible by 3 if the sum of its digits is divisible by 3 e.g. 4035 is divisible by 15 as it ends with a 5 and 4+0+3+5=12 which is divisible by 3
230 or 260
It is divisible by 2 & 3. It is not divisible by 5, 9 & 10. 534 is even → divisible by 2 5 + 3 + 4 = 12 → divisible by 3 534 does not end in 0 or 5 → not divisible by 5 5 + 3 + 4 = 12 → not divisible by 9 534 does not end in 0 → not divisible by 10
15 is divisible by 3 and 5.
it's not divisible by neither 5 or 3
yep it is because 2 is divisible by 2 and 3 is divisible by 3 and 0 is divisible by 5 have fun suckers!
It is divisible by 2 and 3. It isn't divisible by 5 and 10.
To determine if 535 is divisible by 3, you can add the digits together: 5 + 3 + 5 = 13. Since 13 is not divisible by 3, 535 is also not divisible by 3. Therefore, 535 is not divisible by 3.
Is 5225 divisible by 3? A number is divisible by 3, if the sum of its digits is evenly divisible by 3. 5 + 2 + 2 + 5 = 14. Since 14 is not divisible by 3, neither is 5225.
Well, let's take a moment to look at this question. To see if a number is divisible by 3, you can add up the digits and see if that sum is divisible by 3. For 780, 7 + 8 + 0 = 15, which is divisible by 3. But for 320, 3 + 2 + 0 = 5, which is not divisible by 3. So, 780 is divisible by 3. Now, to check if a number is divisible by 5, you can see if the last digit is 0 or 5. In this case, 780 ends in 0, so it's divisible by 5. However, 320 does not end in 0 or 5, so it's not divisible by 5. So, 780 is divisible by both 3 and 5, while 320 is only divisible by 5.
No, look at 5 it is odd and not divisible by 3. false,because if you look at the 5 it is not divisible by 3.