Last active
December 25, 2015 00:29
-
-
Save joeyv/6887860 to your computer and use it in GitHub Desktop.
Simple program to make your friends think your smart.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Scanner; | |
public class Birthday | |
{ | |
public static void main (String[] args) | |
{ | |
double number; | |
double birthday; | |
Scanner scan = new Scanner(System.in); | |
//inport number | |
number = scan.nextDouble(); | |
//Directions | |
System.out.print ("\tSteps:" + "\nFirst, take your month number and multiply that by 5." + "\nNext, add 6 to that number." + "\nThen, multiply that number by 4." + "\nAfter, add 9 to that number." + "\nNow, multiply that number by 5." + "\nLastly, add your birthdate day to the number." + "\n\n Input your number:"); | |
System.out.println (number); | |
//Caculate Birthdate | |
birthday = (number - 165) / 100; | |
System.out.println ("Your Birthday is: " + birthday); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment