UCONN

UCONN
UCONN

Wednesday, August 27, 2025

Assignment#1 due 9/10/25

 Assignment#1 due 9/10/25

https://uconnstamfordslp.blogspot.com/p/linux-explained.html

Note validate major for this list -  make sure you select your major

Engineering - Biomedical Engineering

ACES - Exploratory

Engineering - Mechanical Engineering

Engineering - Civil Engineering

Business - Stamford-Business-Undecided

Engineering - Electrical Engineering

Engineering - Computer Engineering

Engineering - Engineering Physics

Liberal Arts & Sciences - Physiology & Neurobiology

Engineering - Multidisciplinary Engineering

Liberal Arts & Sciences - Economics/Mathematics

Engineering - Environmental Engineering

Liberal Arts & Sciences - Communication


Name
Major - Validate Major
grade - e.g Freshman (same validation as program)
What you want to do?
High school you went to?
Town you live in?
Favorite subject growing up?
What are you passionate about?
Favorite band or musician?
Favorite song?
What company or organization would you like to for?
Send both code and output attachment via email
Attach the my_info.txt file to your email
List all lines of code
Program

#!/bin/bash

# My First scripts

echo "Enter your full name : "

read my_name

echo "Enter your major : "

read my_major

gradyear=2025

cyear=1



while true; do

    echo -n "Enter your class standing (Freshman, Sophomore, Junior, Senior): "

    read standing


    case "$standing" in

        [Ff]reshman)

            echo "✅ You entered: Freshman"

            cyear=4

            break

            ;;

        [Ss]ophomore)

            echo "✅ You entered: Sophomore"

            cyear=3

            break

            ;;

        [Jj]unior)

            echo "✅ You entered: Junior"

            cyear=2

            break

            ;;

        [Ss]enior)

            echo "✅ You entered: Senior"

            cyear=1

            break

            ;;

        *)

            echo "❌ Invalid entry. Please try again."

            ;;

    esac

done

# Perform addition

sum=$((gradyear + cyear))


# Display result

echo "Your Graduation year is $sum"


echo "My Name is : " $my_name > my_profile.txt

echo "My major is : " $my_major >> my_profile.txt

echo "My grade is : " $standing >> my_profile.txt

echo "I will graduate in the year : " $sum >> my_profile.txt


No comments:

Post a Comment

Assignment#1 due 9/10/25

 Assignment#1 due 9/10/25 https://uconnstamfordslp.blogspot.com/p/linux-explained.html Note validate major for this list -  make sure you se...