More Variables and Printing

Code

    /// Name: Rachel Smith
    /// Period: 5
    /// Program Name: More Variables and Printing
    /// File Name: MoreVariablesAndPrinting.java
    /// Date Finished: 9/14/2015
            
    public class MoreVariablesAndPrinting {
                
        public static void main( String[] args ) {
            
            String Name, Eyes, Teeth, Hair;
            int Age, Height, Weight;
            double cHeight, cWeight;
    
            Name = "Rachel M. Smith";
            Age = 16;     // not a lie
            Height = 66;  // inches
            cHeight= Height * 2.54;
            Weight = 120; // lbs
            cWeight= Weight * 0.453592;
            Eyes = "Blue";
            Teeth = "White";
            Hair = "Brown";
    
            System.out.println( "Let's talk about " + Name + "." );
            System.out.println( "She's " + Height + " (or " + cHeight + " cm) inches tall." );
            System.out.println( "She's " + Weight + " (or " + cWeight + " kg) pounds." );
            System.out.println( "Actually, that's not too heavy." );
            System.out.println( "She's got " + Eyes + " eyes and " + Hair + " hair." );
            System.out.println( "Her teeth are usually " + Teeth + " depending on the coffee." );
    
            // This line is tricky; try to get it exactly right.
            System.out.println( "If I add " + Age + ", " + Height + ", and " + Weight
                + " I get " + (Age + Height + Weight) + "." );
        }
    }
    

Picture of the output

Assignment 1