DEV Community

Discussion on: How To Write Better Python Code?

Collapse
 
djamaile profile image
Djamaile

You said no classes, but what would you recommend for repeating arguments? Currently I am using dataclasses for that.

Collapse
 
iiverveii profile image
Priyansi

I never said 'no classes'. Obviously, they have their place like in your case. I said prefer functions over classes and group similar functions into modules rather than merely use a class for behavior grouping :)

Collapse
 
djamaile profile image
Djamaile

Aha thanks, happy coding😉.

Thread Thread
 
iiverveii profile image
Priyansi

You too :D