4 ms·
Yeah i for for loops (in python) x for comprehensions, etc, make sense. But in general, single character variables make code really hard to read.
by SEJeff 4y ago
Yeah i for for loops (in python) x for comprehensions, etc, make sense. But in general, single character variables make code really hard to read.
- ehsankia 4y agoYep, you should just use the best judgement, for example for distance, time in driving_metrics: speed = distance / time is a lot clearer than for d, t in driving_metrics: s = d / t even if it's used in a tiny scope once. But some things don't have a valuable meaning, or the meaning can trivially be inferred.
- SEJeff 4y agoI meant i as in the iterator variable for a counter like when using enumerate() or a c style for loop where you manually specify the list index.