4 ms·
What is this $hi+? You're creating a list that looks like this: [0, 2, …, 2]. It's also common / Pythonic to use uppercase L for lists. If you don't want to us
by ciupicri 1y ago
What is this $hi+? You're creating a list that looks like this: [0, 2, …, 2]. It's also common / Pythonic to use uppercase L for lists.
If you don't want to use global variables just add the result of f to x and stop using the global variable, i.e.
x += f()
- bgwalter 1y agoNot even wrong.
- int_19h 1y ago> It's also common / Pythonic to use uppercase L for lists. Variables always start with a lowercase letter in idiomatic Python unless they're constants or types. Using single-letter uppercase for variables is not unusual in ML Python code, but that also happens to be one of the worst ecosystems when it comes to idiomatic Python and general code quality.