This commit is contained in:
Матвей Карачев 2026-04-04 10:18:16 +03:00
parent 551b0456c4
commit 5a1fb1bd67
2 changed files with 2 additions and 18 deletions

2
.idea/vcs.xml generated
View File

@ -2,6 +2,8 @@
<project version="4"> <project version="4">
<component name="VcsDirectoryMappings"> <component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" /> <mapping directory="" vcs="Git" />
<mapping directory="$PROJECT_DIR$/order_system" vcs="Git" />
<mapping directory="$PROJECT_DIR$/practice_project" vcs="Git" /> <mapping directory="$PROJECT_DIR$/practice_project" vcs="Git" />
<mapping directory="$PROJECT_DIR$/practice_project/order_system" vcs="Git" />
</component> </component>
</project> </project>

18
buga.py
View File

@ -1,18 +0,0 @@
# 10 функций для учета заказов
def get_total(price, count): return price * count
def apply_tax(amount): return amount * 1.2
def get_discount(amount): return amount * 0.9 if amount > 1000 else amount
def format_item(item): return item.strip().capitalize()
def is_valid_count(count): return count > 0
def check_limit(amount): return amount < 100000
def get_status(is_paid): return "Оплачено" if is_paid else "Ожидает"
def calc_shipping(weight): return weight * 50
def get_info(id, item): return f"Заказ #{id}: {item}"
def final_report(res): print(f"Итог: {res} руб.")
if __name__ == "__main__":
# Пример вызова
price = get_total(100, 5)
with_tax = apply_tax(price)
final_report(with_tax)