8000 Moved questions around · zfoxpython/intro-to-python@ffcd36c · GitHub
[go: up one dir, main page]

Skip to content

Commit ffcd36c

Browse files
committed
Moved questions around
1 parent f64a439 commit ffcd36c

File tree

4 files changed

+12
-21
lines changed

4 files changed

+12
-21
lines changed

session_10/answers/A5.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
2-
# 5. Create the instance attributes fullname and email in the Employee class. Given a person's first and last names:
3-
# - Form the fullname by simply joining the first and last name together, separated by a space.
4-
# - Form the email by joining the first and last name together with a . in between, and follow it with @company.com at the end. Make sure everything is in lowercase.
1+
# 5. Write a class which has two methods get_word and print_word.
2+
# - get_word accepts a string from the user and print_word prints the string in upper case.
53

session_10/answers/A6.py

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,9 @@
1-
# 6. Write a class which has two methods get_word and print_word.
2-
# - get_word accepts a string from the user and print_word prints the string in upper case.
1+
# 6. Create a Sandwich class with the attributes order_number and ingredients (which is given as a list).
2+
# - Only the ingredients will be given as input.
33

4+
# You should also make it possible to choose a ready-made sandwich rather than typing out the ingredients manually. Also hard-code the following sandwich flavours.
5+
6+
# Name Ingredients
7+
# vegan_hot vegan cheese, meatless meatballs, jalapenos
8+
# meat_festival steak, peppers, cheese
9+
# garden_feast spinach, olives, mushroom, eggs

session_10/answers/A7.py

Lines changed: 0 additions & 9 deletions
This file was deleted.

session_10/exercises/exercises_10.md

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -27,14 +27,10 @@
2727
- iii. Delete the wheels.
2828

2929

30-
5. Create the instance attributes fullname and email in the Employee class. Given a person's first and last names:
31-
- Form the fullname by simply joining the first and last name together, separated by a space.
32-
- Form the email by joining the first and last name together with a . in between, and follow it with @company.com at the end. Make sure everything is in lowercase.
33-
34-
6. Write a class which has two methods get_word and print_word.
30+
5. Write a class which has two methods get_word and print_word.
3531
- get_word accepts a string from the user and print_word prints the string in upper case.
3632

37-
7. Create a Sandwich class with the attributes order_number and ingredients (which is given as a list).
33+
6. Create a Sandwich class with the attributes order_number and ingredients (which is given as a list).
3834
- Only the ingredients will be given as input.
3935

4036
You should also make it possible to choose a ready-made sandwich rather than typing out the ingredients manually. Also hard-code the following sandwich flavours.

0 commit comments

Comments
 (0)
0