Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
dazmax
on Oct 24, 2013
|
parent
|
context
|
favorite
| on:
Why Python uses 0-based indexing. It's because of ...
Agreed. It seems messy at first, but what Ruby does is make it possible to write code in the most readable way.
a[first..last] left, right = a[0...pivot], a[pivot...a.len] a[start, len]
If the coder picks the right one and the variable names are good, the reader won't have to think about it.
Consider applying for YC's Winter 2027 batch!
Applications
are open till November 2.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search: