Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- import java.util.Arrays;
- public class Vacation {
- //dream perfect paradise like a welcome board, then press a button to start
- //ideal destinations include
- //italy eastern hemisphere
- //usa western hemisphere
- //puerto rico near USA
- // egypt eastern hemisphere
- //show continents for them to choose
- //italy climate?
- //tropical climate only warmth no snow
- //usa has snow
- //egypt is hot
- // should they go in order? kind of like telling a story?
- // should the prices be involved? what currency would they be in?
- //language?
- // include at the end a description of the final destination that summarizes their choices
- public static void main(String[] args) {
- Integer[] answers = new Integer[14];
- String[] climates = new String[4];
- climates[0] = "Tropical Climate";
- climates[1] = "Cold Climate";
- climates[2] = "Dry Climate";
- climates[3] = "Arid Climate";
- for (int i = 0; i < climates.length; i++) {
- System.out.println(i + " " + climates[i]);
- }
- System.out.println("Pick a Climate");
- Scanner keyboard1 = new Scanner(System.in);
- int answerclimate = keyboard1.nextInt();
- answers[0] = answerclimate;
- String[] foods = new String[4];
- foods[0] = "Spaghetti";
- foods[1] = "Hamburger";
- foods[2] = "Rice and Beans";
- foods[3] = "Falafel";
- for (int i = 0; i < foods.length; i++) {
- System.out.println(i + " " + foods[i]);
- }
- System.out.println("Pick a food");
- Scanner keyboard2 = new Scanner(System.in);
- int answerfood = keyboard2.nextInt();
- answers[1] = answerfood;
- String[] beverages = new String[4];
- beverages[0] = "Tea";
- beverages[1] = "Coffee";
- beverages[2] = "Piña Colada";
- beverages[3] = "Egyptian Flask";
- for (int i = 0; i < beverages.length; i++) {
- System.out.println(i + " " + beverages[i]);
- }
- System.out.println("Pick a beverage");
- Scanner keyboard3 = new Scanner(System.in);
- int answerbeverages = keyboard3.nextInt();
- answers[2] = answerbeverages;
- String[] transportations = new String[4];
- transportations[0] = "Airplane";
- transportations[1] = "Car";
- transportations[2] = "Boat";
- transportations[3] = "Tuk Tuks";
- for (int i = 0; i < transportations.length; i++) {
- System.out.println(i + " " + transportations[i]);
- }
- System.out.println("Which mode of transportation would you ideally use?");
- Scanner keyboard4 = new Scanner(System.in);
- int answertransportations = keyboard4.nextInt();
- answers[3] = answertransportations;
- // this choice has no value
- String[] durations = new String[4];
- durations[0] = "about a week";
- durations[1] = "about a month";
- durations[2] = "about a year";
- durations[3] = "about a day";
- for (int i = 0; i < durations.length; i++) {
- System.out.println(i + " " + durations[i]);
- }
- System.out.println("How long would you like to travel?");
- Scanner keyboard5 = new Scanner(System.in);
- int answerdurations = keyboard5.nextInt();
- answers[4] = answerdurations;
- String[] animals = new String[4];
- animals[0] = "pigeon";
- animals[1] = "wolf";
- animals[2] = "parrot";
- animals[3] = "camel";
- for (int i = 0; i < animals.length; i++) {
- System.out.println(i + " " + animals[i]);
- }
- System.out.println("Pick the animal you would like to see");
- Scanner keyboard6 = new Scanner(System.in);
- int answeranimals = keyboard6.nextInt();
- answers[5] = answeranimals;
- String[] guides = new String[4];
- guides[0] = "italian artist with the hat";
- guides[1] = "usa guide";
- guides[2] = "hawaiian shirt";
- guides[3] = "egyptian turbante";
- for (int i = 0; i < guides.length; i++) {
- System.out.println(i + " " + guides[i]);
- }
- System.out.println("Select which you would want as a tour guide");
- Scanner keyboard7 = new Scanner(System.in);
- int answerguides = keyboard7.nextInt();
- answers[6] = answerguides;
- String[] sculptures = new String[4];
- sculptures[0] = "European statue Venus de Milo";
- sculptures[1] = "Civil War Artifact";
- sculptures[2] = "Caribbean Underwater sculpture of Coral Reef or Atalantis";
- sculptures[3] = "Egyptian statue of Tutankhamon";
- for (int i = 0; i < sculptures.length; i++) {
- System.out.println(i + " " + sculptures[i]);
- }
- System.out.println("Select your favorite sculpture");
- Scanner keyboard8 = new Scanner(System.in);
- int answersculptures = keyboard8.nextInt();
- answers[7] = answersculptures;
- String[] landscapes = new String[4];
- landscapes[0] = "Mountains";
- landscapes[1] = "big house in usa";
- landscapes[2] = "Ocean";
- landscapes[3] = "Desert";
- for (int i = 0; i < landscapes.length; i++) {
- System.out.println(i + " " + landscapes[i]);
- }
- System.out.println("Select your favorite landscape");
- Scanner keyboard9 = new Scanner(System.in);
- int answerlandscapes = keyboard9.nextInt();
- answers[8] = answerlandscapes;
- String[] landmarks = new String[4];
- landmarks[0] = "Tower of Pisa";
- landmarks[1] = "US Presidents";
- landmarks[2] = "Playa Bioluminicente Vieques";
- landmarks[3] = "Pyramids en Egypt";
- for (int i = 0; i < landmarks.length; i++) {
- System.out.println(i + " " + landmarks[i]);
- }
- System.out.println("Select your favorite landmark");
- Scanner keyboard10 = new Scanner(System.in);
- int answerlandmarks = keyboard10.nextInt();
- answers[9] = answerlandmarks;
- String[] presidents = new String[4];
- presidents[0] = "Quirinal Palace";
- presidents[1] = "White House";
- presidents[2] = "Fortaleza en Viejo San Juan";
- presidents[3] = "Africa Presidents Place";
- for (int i = 0; i < presidents.length; i++) {
- System.out.println(i + " " + presidents[i]);
- }
- System.out.println("Select the one you like the best");
- Scanner keyboard11 = new Scanner(System.in);
- int answerpresidents = keyboard11.nextInt();
- answers[10] = answerpresidents;
- // the outcome of this question has no value
- String[] luggages = new String[4];
- luggages[0] = "Simple Backpack";
- luggages[1] = "Light suitcase";
- luggages[2] = "Heavy suicase";
- luggages[3] = "Heavy Exploring Backpack";
- for (int i = 0; i < luggages.length; i++) {
- System.out.println(i + " " + luggages[i]);
- }
- System.out.println("Pick a Bag");
- Scanner keyboard12 = new Scanner(System.in);
- int answerluggages = keyboard12.nextInt();
- answers[11] = answerluggages;
- String[] snacks = new String[4];
- snacks[0] = "Kinder Brioss";
- snacks[1] = "Welchs";
- snacks[2] = "Piragua";
- snacks[3] = "Motto";
- for (int i = 0; i < snacks.length; i++) {
- System.out.println(i + " " + snacks[i]);
- }
- System.out.println("Pick a Snack");
- Scanner keyboard13 = new Scanner(System.in);
- int answersnacks = keyboard13.nextInt();
- answers[12] = answersnacks;
- String[] desserts = new String[4];
- desserts[0] = "Gelato";
- desserts[1] = "Kit Kat";
- desserts[2] = "Tembleque";
- desserts[3] = "Basbusa";
- for (int i = 0; i < desserts.length; i++) {
- System.out.println(i + " " + desserts[i]);
- }
- System.out.println("Pick a Dessert");
- Scanner keyboard14 = new Scanner(System.in);
- int answerdesserts = keyboard14.nextInt();
- answers[13] = answerdesserts;
- int Final0 = 0;
- for (int i = 0; i < 14; i++) {
- if (answers[i] == 0)
- Final0 = Final0 + 1;
- }
- int Final1 = 0;
- for (int i = 0; i < 14; i++) {
- if (answers[i] == 1)
- Final1 = Final1 + 1;
- }
- int Final2 = 0;
- for (int i = 0; i < 14; i++) {
- if (answers[i] == 2)
- Final2 = Final2 + 1;
- }
- int Final3 = 0;
- for (int i = 0; i < 14; i++) {
- if (answers[i] == 3)
- Final3 = Final3 + 1;
- }
- }
- class FinalNumber {
- int[] number = {0, 1, 2, 3};
- Arrays.sort(number);
- System.out.printf(" Your dream destination is: " + Arrays.toString(number));
- }
- class Final {
- String destination;
- void speak() {
- System.out.println("Your travel destination is: " + destination);
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement