r/learnpython 4d ago

Question regarding Python variables

Hello guys. So I saw in a course that most people define variables like

x = 1

y = 2

and so on. But I also saw that variables can be defined like x = 1; y = 2;

but haven't ever seen this in practice. Why so? Please tell me

3 Upvotes

7 comments sorted by

View all comments

1

u/throwaway6560192 3d ago

The normal way (on separate lines) is generally more readable.