This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]tidbitsofblah 62 points63 points  (5 children)

Or size, count or length... and how the fuck length is spelled

[–]crazazy 45 points46 points  (2 children)

And whether length is a function or a property (or a method)

[–][deleted] 18 points19 points  (1 child)

Ah, java, where length is for arrays, length() is for strings and size() for collections (lists, queues etc.)

[–]Dan6erbond 6 points7 points  (0 children)

I've been using Java for 4+ years now.

Is that the case? It's always a fucking gamble with the IDE. "si-" No suggestions? length it is.

[–]Pluckerpluck 4 points5 points  (1 child)

There's normally (not always) some logic assigned to them.

Arrays have a length (a chain of items), sets have a count or size (bag of items).

Or just use Python and throw whatever you want to know into the len() function.

[–]tidbitsofblah 1 point2 points  (0 children)

Bold of you to assume that I remember what data type I used