Asked by nick
Project 1: -- Sandbox name: project1
Write a program asking the user to answer the following about themselves to answer these statements.
My name is ____.
I am ______ years old.
My favorite color is ______.
I want to work as a ______ after graduation.
Project 2: -- Sandbox name: project2
Prompt the user for name, their age, and what state they were born in. Then print out the name that was given, the users age, and which state they were born in.
Here is an example of what you should print.
Name: Erin
Age: 32
Born in: Hawaii
Project 3: -- Sandbox name: project3
Prompt the user for their name, and how many shirts they would like to buy. Then print out the name that was given, as well as how many shirts they would like to buy.
Here is an example of what you should print:
Hi Erin, you want 5 shirts.
Project 4: -- Sandbox name: project4
Create a program that multiplies two INTEGER numbers and prints the result
Number 1 is 11
Number 2 is 13
The multiplication of 11 and 13 is 143
Project 5: -- Sandbox name: project5
Create a program that asks for 5 test scores. Then calculate the average of these test scores and print it as shown below.
Sample Output
Test 1: 85
Test 2: 80
Test 3: 90
Test 4: 83
Test 5: 87
Your average test score is 85.0
Project 6: -- Sandbox name: project6
Prompt the user for a number. Write a program that reads an integer number and prints its previous and next numbers. See the example below:
Example input:
Enter a number: 179
Example output:
The next number for the number 179 is 180
the previous number for the number 179 is 178
All Answers 1
Answered by
GPT-5 mini
AI
Below are simple Python 3 programs for each sandbox/project. Save each snippet as the corresponding file (e.g., project1.py) and run with Python 3.
Project 1 (project1.py)
- Prompts for the four items and prints the four sentences.
```
name = input("Enter your name: ")
age = input("Enter your age: ")
color = input("Enter your favorite color: ")
job = input("Enter what you want to work as after graduation: ")
print(f"My name is {name}.")
print(f"I am {age} years old.")
print(f"My favorite color is {color}.")
print(f"I want to work as a {job} after graduation.")
```
Project 2 (project2.py)
- Prompts for name, age, state born and prints them as in the example.
```
name = input("Name: ")
age = input("Age: ")
state = input("Born in: ")
print()
print(f"Name: {name}")
print()
print(f"Age: {age}")
print()
print(f"Born in: {state}")
```
Project 3 (project3.py)
- Prompts for name and number of shirts, prints the sentence.
```
name = input("Enter your name: ")
shirts = input("How many shirts would you like to buy? ")
print(f"Hi {name}, you want {shirts} shirts.")
```
Project 4 (project4.py)
- Multiplies two integer numbers (11 and 13) and prints the result.
```
n1 = 11
n2 = 13
print(f"Number 1 is {n1}")
print(f"Number 2 is {n2}")
print(f"The multiplication of {n1} and {n2} is {n1 * n2}")
```
Project 5 (project5.py)
- Asks for 5 test scores, prints each prompt (as shown), then prints the average.
```
scores = []
for i in range(1, 6):
score = float(input(f"Test {i}: "))
scores.append(score)
average = sum(scores) / 5
print(f"Your average test score is {average}")
```
Project 6 (project6.py)
- Reads an integer and prints its next and previous numbers (matching the example formatting).
```
n = int(input("Enter a number: "))
print(f"The next number for the number {n} is {n + 1}")
print(f"the previous number for the number {n} is {n - 1}")
```
If you want any of these adapted to a different language or made more robust (input validation, formatting of average to a fixed decimal places, etc.), tell me which one and I'll adjust.
Project 1 (project1.py)
- Prompts for the four items and prints the four sentences.
```
name = input("Enter your name: ")
age = input("Enter your age: ")
color = input("Enter your favorite color: ")
job = input("Enter what you want to work as after graduation: ")
print(f"My name is {name}.")
print(f"I am {age} years old.")
print(f"My favorite color is {color}.")
print(f"I want to work as a {job} after graduation.")
```
Project 2 (project2.py)
- Prompts for name, age, state born and prints them as in the example.
```
name = input("Name: ")
age = input("Age: ")
state = input("Born in: ")
print()
print(f"Name: {name}")
print()
print(f"Age: {age}")
print()
print(f"Born in: {state}")
```
Project 3 (project3.py)
- Prompts for name and number of shirts, prints the sentence.
```
name = input("Enter your name: ")
shirts = input("How many shirts would you like to buy? ")
print(f"Hi {name}, you want {shirts} shirts.")
```
Project 4 (project4.py)
- Multiplies two integer numbers (11 and 13) and prints the result.
```
n1 = 11
n2 = 13
print(f"Number 1 is {n1}")
print(f"Number 2 is {n2}")
print(f"The multiplication of {n1} and {n2} is {n1 * n2}")
```
Project 5 (project5.py)
- Asks for 5 test scores, prints each prompt (as shown), then prints the average.
```
scores = []
for i in range(1, 6):
score = float(input(f"Test {i}: "))
scores.append(score)
average = sum(scores) / 5
print(f"Your average test score is {average}")
```
Project 6 (project6.py)
- Reads an integer and prints its next and previous numbers (matching the example formatting).
```
n = int(input("Enter a number: "))
print(f"The next number for the number {n} is {n + 1}")
print(f"the previous number for the number {n} is {n - 1}")
```
If you want any of these adapted to a different language or made more robust (input validation, formatting of average to a fixed decimal places, etc.), tell me which one and I'll adjust.
Submit Your Answer
We prioritize human answers over AI answers.
If you are human, and you can answer this question, please submit your answer.