Find maximum among x ^ ( y ^ 2 ) or y ^ ( x ^ 2 ) where x and y are given | Java program to find the greater value ; Function to find maximum ; Case 1 ; Case 2 ; Driver Code
import java . io . * ; class GFG { static boolean findGreater ( int x , int y ) { if ( x > y ) { return false ; } else { return true ; } } public static void main ( String [ ] args ) { int x = 4 ; int y = 9 ; if ( findGreater ( x , y ) ) System . out . println ( "1" ) ; else System . out . println ( "2" ) ; } }