Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion level_1/1.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from constants import ___


def is_user_banned(user_id: ___) -> ___:
def is_user_banned(user_id: int) -> bool:
pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/10.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from constants import ___


def stringify(value: ___) -> ___:
def stringify(value: str | int | float | None) -> str:
pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/2.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from constants import ___


def is_adult(age: ___, country_name: ___) -> ___:
def is_adult(age: int, country_name: str) -> bool:
pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/3.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from constants import ___


def compose_full_name(first_name: ___, last_name: ___, middle_name: ___) -> ___:
def compose_full_name(first_name: str, last_name: str, middle_name: str) -> str:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Глянь внимательнее на вызовы функции, у мидл нейма не такая аннотация.

pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/4.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from constants import ___


def calculate_age(date_of_birth: ___) -> ___:
def calculate_age(date_of_birth: datetime.date) -> int:
pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/5.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from constants import ___


def is_correct_email(raw_email: ___) -> ___:
def is_correct_email(raw_email: str) -> bool:
pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/6.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from constants import ___


def is_loan_amount_too_big(loan_amount_usd: ___, max_loan_amount_for_user_usd: ___) -> ___:
def is_loan_amount_too_big(loan_amount_usd: int, max_loan_amount_for_user_usd: int | None) -> bool:
pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/7.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from constants import ___


def send_email(header: ___, text_content: ___, send_to: ___) -> ___:
def send_email(header: str, text_content: str, send_to: str) -> bool | None:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Непонятно, почему в возвращаемый тип затесался бул, вроде ничего на это не намекает.

pass


Expand Down
3 changes: 2 additions & 1 deletion level_1/8.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
import decimal
import uuid
from _decimal import Decimal

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Этот импорт лишний. Выше есть импорт модуля decimal, поэтому просто используй decimal.Decimal для аннотации.


from constants import ___


def get_user_balance(user_id: ___) -> ___:
def get_user_balance(user_id: uuid.UUID) -> Decimal:
pass


Expand Down
2 changes: 1 addition & 1 deletion level_1/9.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from constants import ___


def is_correct_int(raw_int: ___) -> ___:
def is_correct_int(raw_int: str | None) -> bool:
pass


Expand Down