Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

a bit like knights... test passed #615

Open
wants to merge 7 commits into
base: master
Choose a base branch
from

Conversation

Narberal90
Copy link

No description provided.

app/data.py Outdated
Comment on lines 4 to 11
class Data:
data = None

@staticmethod
def load_config(filename: json) -> dict:
with open(filename, "r") as file:
info = json.load(file)
return info

Choose a reason for hiding this comment

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

Why you need a class for this?
You have only one method which is anyway static

app/customer.py Outdated
Comment on lines 23 to 24
x, y = self.location
x1, y1 = shop.location

Choose a reason for hiding this comment

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

not good names for variables)

app/customer.py Outdated
self.name = data.get("name")
self.product_cart = data.get("product_cart")
self.location = data.get("location")
self.money = data.get("money")

Choose a reason for hiding this comment

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

Convet it to Decimal

app/main.py Outdated
for customer in Customer.group_customers:
print(f"{customer.name} has {customer.money} dollars")

shop_choice = [None, float("inf")]

Choose a reason for hiding this comment

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

Why you need a list here?
You just use it everywhere like two separate components

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.

3 participants