Solved Please Write A Program In Java For The Following

Solved Please Write A Program In Java For The Following