Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /**
- A class to compare numbers.
- */
- public class Numbers
- {
- /**
- Checks whether four numbers are all the same
- @return true if all of the numbers a, b, c, d are equal to another
- */
- public boolean allTheSame(int a, int b, int c, int d)
- {
- return (a == b && a == c && a == d) ? true : false;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement