What If


 public class wut
{
    public static void main( String[] args )
    {
        int people = 20;
        int cats = 20;
        int dogs = 15;
        
        if (people < cats )
        {
            System.out.println( "Too many cats! The world is doomed!!!");
        }
        
        if ( people > cats )
        {
            System.out.println( "Thank god... cats are just annoying...");
        }
        if ( people < dogs )
        {
            System.out.println( "The world is pretty full of friendly dogs :)");
        }
        if ( people > dogs)
        {
            System.out.println( "...I guess some people just have to be lonely");
        }
        // this is going to activate if the number of cats and dogs are either higher or lowwer than the number of people, but if they are equal, nothing will happen. This is caused by the curly brackets
        dogs += 5;
        
        		if ( people >= dogs )
		{
			System.out.println( "People are greater than or equal to dogs." );
		}

		if ( people <= dogs )
		{
			System.out.println( "People are less than or equal to dogs." );
		}

		if ( people == dogs )
		{
			System.out.println( "People are dogs." );
		}
	}
}
    

Picture of the output

Assignment 33