## 4 replies

Last post Jan 08, 2015 05:12 AM by Akritythakuri

Member

30 Points

60 Posts

### multpiles of 4

Jan 08, 2015 02:59 AM|Akritythakuri|LINK

How to check if a number is multiples of 4 or not?

Star

9011 Points

2395 Posts

### Re: multpiles of 4

Jan 08, 2015 03:12 AM|Lokesh B R|LINK

Hi,

you can use (%) operator to check.

```select
case
when 24%4 = 0 then 'Yes'
when 24%4 = 1 then 'No'
end```
Mark the post as answer, if it helps you.

Member

610 Points

286 Posts

### Re: multpiles of 4

Jan 08, 2015 03:27 AM|arindamnayak|LINK

Use % operator to check divisibility.

Like following.

int k = 24;

if(k%4 == 0)

// divisible

else

// not

MCSD - 2014
MCSA
-----------------------
If your query resolves by my suggestion/help, please mark my reply as answer, that will help community .

Contributor

6294 Points

5440 Posts

### Re: multpiles of 4

Jan 08, 2015 03:56 AM|wmec|LINK

#### Akritythakuri

How to check if a number is multiples of 4 or not?

Try

```select case when 16%4=0 then 'yes' else 'no' end
```

Many Thanks & Best Regards,
HuaMin Chen

Member

30 Points

60 Posts

### Re: multpiles of 4

Jan 08, 2015 05:12 AM|Akritythakuri|LINK

thanks guys!!