mirror of
https://github.com/TheAlgorithms/Java.git
synced 2025-07-08 02:04:31 +08:00
Add IsEven Algorithm (#4301)
Co-authored-by: BamaCharanChhandogi <b.c.chhandogi@gmailcom>
This commit is contained in:

committed by
GitHub

parent
251157059c
commit
1ef700e850
12
src/main/java/com/thealgorithms/bitmanipulation/IsEven.java
Normal file
12
src/main/java/com/thealgorithms/bitmanipulation/IsEven.java
Normal file
@ -0,0 +1,12 @@
|
||||
package com.thealgorithms.bitmanipulation;
|
||||
|
||||
/**
|
||||
* Converts any Octal Number to a Binary Number
|
||||
* @author Bama Charan Chhandogi (https://github.com/BamaCharanChhandogi)
|
||||
*/
|
||||
|
||||
public class IsEven {
|
||||
public static boolean isEven(int number) {
|
||||
return (number & 1) == 0;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user