Rosenlof-+Java

/** DogYears.java converts your dogs age into dog years.

* @author 2014246

* @verison for Alice+Java book

*/ import java.util.Scanner; public class DogYears {

public static void main(String[] args) {

System .out. print( "How old is your dog?" ); // //line that asks the user how old the dog is in human years//

// Scanner keyboard = new Scanner(System.in); // // Java 1.5 or later

double HumanYears = keyboard.nextDouble; // //Allows the user to enter the dogs age in human years//

// double DogYears = HumanYears * 7;// // Math for converting human years to dog years

System .out. println( "Your dog is " + DogYears + " years old in dog years!" ); // This line executes the math on converting human years to dog years and then explains to the user how old your dog is in dog years

} }