answersLogoWhite

0

You can use one of the Math.max() methods, or the ternary operator, that is, one of the following:

Math.max(a, b)

a > b ? a : b

User Avatar

Wiki User

12y ago

Still curious? Ask our experts.

Chat with our AI personalities

BlakeBlake
As your older brother, I've been where you are—maybe not exactly, but close enough.
Chat with Blake
ViviVivi
Your ride-or-die bestie who's seen you through every high and low.
Chat with Vivi
JordanJordan
Looking for a career mentor? I've seen my fair share of shake-ups.
Chat with Jordan

Add your answer:

Earn +20 pts
Q: What is java statement to find the maximum between two values?
Write your answer...
Submit
Still have questions?
magnify glass
imp