Find Largest of Three Numbers

public static void main(String[] args)

{

int n1=10, n2=20, n3=40;

if ((n1>n2) &&(n1>n3))
{
System.out.println(“Maximum value:”+n1);
}
if ((n2>n1) &&(n2>n3))
{
System.out.println(“Maximum value:”n2);

}

if ((n3>n1) &&(n3>n2))
{
System.out.println(“Maximum value:”n3);

}

}