/home/chloe/ASDV-Java/lab8_ChloeFontenot/src/main/java/com/chloefontenot/lab8_chloefontenot/Switch4.java
/*
 * Click nbfs://nbhost/SystemFileSystem/Templates/Licenses/license-default.txt to change this license
 * Click nbfs://nbhost/SystemFileSystem/Templates/Classes/Class.java to edit this template
 */
package com.chloefontenot.lab8_chloefontenot;

import java.util.Scanner;

/**
 *
 * @author chloe
 */
public class Switch4 {

    public static void main(String[] args) {
        // Define vars
        String dayOfWeekString = "Nullday",
                ordinal = "0th";

        // Create scanner
        Scanner input = new Scanner(System.in);

        // Prompt for input
        System.out.print("Enter a day of the week (Case-Sensitive): ");
        dayOfWeekString = input.next();

        // Switch moment
        switch (dayOfWeekString) {
            case "Sunday":
                ordinal = "1st";
                break;
            case "Monday":
                ordinal = "2nd";
                break;
            case "Tuesday":
                ordinal = "3rd";
                break;
            case "Wednesday":
                ordinal = "4th";
                break;
            case "Thursday":
                ordinal = "5th";
                break;
            case "Friday":
                ordinal = "6th";
                break;
            case "Saturday":
                ordinal = "7th";
                break;
        }
        // Print output
        System.out.println(dayOfWeekString + " is the " + ordinal + " day of the week.");
    }
}