Skip to content

Pizza project#8

Open
veronica-kirenkina wants to merge 5 commits intoveronica-kirenkina-3from
veronica-kirenkina-4
Open

Pizza project#8
veronica-kirenkina wants to merge 5 commits intoveronica-kirenkina-3from
veronica-kirenkina-4

Conversation

@veronica-kirenkina
Copy link
Owner

No description provided.

@veronica-kirenkina veronica-kirenkina changed the title Create pizza.py Pizza project Nov 16, 2023
:return: None
"""
for pizza_name in Pizza.__subclasses__():
if pizza_name().__class__.__name__.lower() == pizza:

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Лучше избегать лишней вложенности. Здесь можно было сначала проверить, что pizza не из меню -> вызвать ошибку, и потом уже без вложенности продолжать функцию

return decorator


@log

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Почему здесь ничего не пишется фраза с картинкой?

class Pizza:
"""Базовый класс для всех видов пицц"""

def __init__(self, size: str = 'L', name: str = None, extra_ingredients: list = []):

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Размер пиццы в итоге нигде не задаётся

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants