3 ms·
Ask HN: Why Python developers named 'bytearray' in Python 3.x?
Python 3.x the ascii string type is named as type(bytearray(b'bytearrays')
"bytearray".It seems quite long characters.
Did they consider other options like "byte" or "string" something like that?
What was the particular reason for the namespaces?
- lmm 12y ago"string" would be confusing. "byte" would be misleading. "bytearray" is what it is - it's an array of bytes. I don't know about the developers, but it seems like an obviously better choice to me.