To find Whether the given Number in Positive Or Not
public class PositiveNegative { public void main(int n) { if (n>0) System.out.println("The number is positive"); else System.out.println("The number is negative"); } }
/*TO FIND THE AREA OF THE TRIANGLE */ public class TRIANGLE { public static void main(String args[]) { int b=10; int h=9; double area; area =0.5*b*h; System.out.println("the area of the triangle is" +area); } }