Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Exercise:
- def __init__(self, topic, course_name, judge_link, problems):
- self.topic = topic
- self.course_name = course_name
- self.judge_link = judge_link
- self.problems = problems
- collection = []
- text = input()
- while text != "go go go":
- v = text.split(" -> ")
- collection.append(Exercise(v[0], v[1], v[2], v[3].split(", ")))
- text = input()
- for item in collection:
- print(f"Exercises: {item.topic}")
- print(f'Problems for exercises and homework for the "{item.course_name}" course @ SoftUni.')
- print(f"Check your solutions here: {item.judge_link}")
- [print(f"{a}. {problem}") for a, problem in enumerate(item.problems, 1)]
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement