Thinks that 33 + 1 equals 331, and forces you to write sums as "(a-0) + (b-0)" in order to add them correctly?
</rhetorical>
gominokouhai: (Default)

From: [personal profile] gominokouhai


Any weakly typed language that uses + as a concatenation operator, rather than for numeric addition.

Use of `+' to mean `+' is only syntactic sugar, anyway. You should forsake such minor concerns.

Go on then... which language?
ext_79424: Line drawing of me, by me (Default)

From: [identity profile] spudtater.livejournal.com


Well, that's alright. But for the '-' operator to automatically cast strings to ints, but not the '+'... a hell of a lot of people are going to be wondering why only some of their sums are turning out right.

(N.B. adding 1 to 33 still lets you index position number 331, so it's not even like there's a handy error to show you where you're going wrong. I finally worked it out using debug statements.)

plus( plus( Syntactic sugar ) )   8^)
.

Profile

spudtater: (Default)
spudtater

Most Popular Tags

Page Summary

Powered by Dreamwidth Studios

Style Credit

Expand Cut Tags

No cut tags