answersLogoWhite

0


Best Answer

I assume you mean is an if the number is an integer multiple of 3
i am unfamiliar with C but the theory would be,
find if a is integer multiple of 3
b=a/3
b==round(b).
if 1 "yes"
else "no"
this is an inefficiency way but will get the job done

User Avatar

Wiki User

14y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Write a program to check whether the number is divisible by 3 or not by using the?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

Write a program By using if else statement to read a number and check whether it is positive or negative?

write a c++program by using if statement to read a number and check whether it is positive or negative


How do you write a program to test if a given number is divisible by 6 in C programming?

if ( x % 6 == 0 ){ printf( "%d is divisible by 6", x ); } else { printf( "%d is not divisible by 6", x ); }


Write a program to find the number of and sum of all integers greater than 100 and less than 200 that are divisible by 77?

What for? There is only a 154 inside that is divisible by 77...


How do you write a program to twin print prime numbers from 1 to 50 in PHP?

I suggest you write an outer loop, that loops through all the numbers from 1 to 50. Call the variable that controls the loop something like "number".Then, initially assume the number is a prime (with a variable such as "isprime"); and write another loop that compares whether the number is divisible by any number from 2 to number-1. Call the controlling variable "factor". If number is divisible by factor, then it is not a prime, and you can exit the loop. At the end of the inner loop, if the variable "isprime" is still true, then you print the number.


How do you write c program to test that an integer number is divisible by 2?

int isDivisibleByTwo(int N) return N % 2 == 0;


Writes a c program to find the sum of all integers between 1 and n?

Write a program to find the number and sum of all integers from 100 to 300 that are divisible by 11


Program for print prime all number from 1 to 100 in foxpro?

Prime numbers are numbers that are only divisible by themselves and the number 1. You can write a program to print all prime numbers from 1 to 100 in FoxPro.


How do you write a C program to check whether the number is odd or even Ps-using DEV complier?

To write a C program to determine if something is odd or even you need to be a programmer. To write a program in C is complicate and only done by programmers.


A number is divisible by 4 if the last two digits are divisible by 4 write yes on the line if the number 324 is divisible by 4 and no if it is not?

Yes.


Can you write a number that is divisible by 6 but not 3?

15


Lab manual in mca 1st sem from ignou?

write a program in C to check whether a given number is apalindrome or not


Write a program to convert a 2 digit BCD number into hexadecimal number?

Write a program to convert a 2-digit BCD number into hexadecimal