Prog 11: Math and Numbers
///Name: Ilana Levy
///Period: 5
///Program Name: Numbers and Math
///File Name: math.java
///Date Finished: 9/6/2015
public class math
{ //CHECK OUT FLOAT ON THIS LINE! WHAT THE H--- DO I DO! HELP ME MR DAVIS!!!!!!!!!!!!!!!!!!!!
public static void main( String[] args )
{
float
//I will now count my chickens
System.out.println( "I will now count my chickens:" );
// Hens 30
System.out.println("Hens " + (25 + 30 / 6) );
//Roosters 97
System.out.println( "Roosters " + ( 100 - 25 * 3 % 4 ) );
//Now I will count the eggs:
System.out.println( "Now I will count the eggs:" );
// 7
System.out.println( 3 + 2 + 1 - 5 + 4 % 2 - 1 / 4 + 6);
//Is it true that 3 + 2 < 5 - 7
System.out.println( "Is it true that 3 + 2 < 5 - 7?" );
//false
System.out.println( 3 + 2 < 5 - 7 );
//What is 3 + 2? 5
System.out.println( "What is 3 + 2?" + (3 + 2) );
//What is 5 - 7? -2
System.out.println( "What is 5 - 7?" + ( 5 - 7 ) );
//Oh, that's why it's false.
System.out.println( "Oh, that's why it's false." );
//How about some more.
System.out.println( "How about a little fire, scarecrow." );
//Is it greater? true
System.out.println( "Is it greater?" + ( 5 > -2) );
//Is it greater or equal? true
System.out.println( "Is it greater or equal?" + ( 5 >=2) );
//Is it less or equal? false
System.out.println( "Is it less or equal?" + ( 5 <= 2) );
}
}