Assignemnt #17

Code

          /// Name: Holden Ganch
          /// Period: 7
          /// Program Name: seventeenth Program
          /// File Name: MathOperations.java
          /// Date Finished: 9/21/2015



                  public class MathOperations
       {
           public static void main( String[] args )
           {
               int h, b, g, k, H, t, f;
               double q, r, s;
               String one, two, both;
       
               h = 8;
               b = 88
               ;
               System.out.println( "h is " + h + ", b is " + b );
       
               g = h + b;
               System.out.println( "h+b is " + g );
               k = h - b;
               System.out.println( "h-b is " + k );
               H = h+b*3;
               System.out.println( "h+b*3 is " + H );
               t = b / 2;
               System.out.println( "b/2 is " + t );
       
               q = 8.8;
               System.out.println( "\nx is " + q );
               r = q*q;
               System.out.println( "q*q is " + r );
               s = b / 2;
               System.out.println( "b/2 is " + s );
               System.out.println();
       
               one = "Bat";
               two = "man";
               both = one + two;
               System.out.println( both );
           }
       }



    

Picture of the output

Assignment 17