7 ms·
A math tutor of mine was actually pretty angry at computer science for writing things like `a=1; a=2; //so 1=2 ?` I guess he'd rather have the "assign 42 to age
by qbonnard 6y ago
A math tutor of mine was actually pretty angry at computer science for writing things like `a=1; a=2; //so 1=2 ?`
I guess he'd rather have the "assign 42 to age"... Except he'd probably read `42 => age` as "42 implies age", which would probably cause him more sleepless nights ;)
- toxik 6y agoHe’d probably like a := 42 which is in a lot of languages actually! Also Erlang and other fp’s do consider = equivalence.
- Izkata 6y agoI noticed a year or two ago when I'm pseudocoding I seem to default to "age <- 42" which I kinda like more...
- choward 6y agoI'm a big fan of immutability and using constantly so I agree with your tutor.
- danellis 6y ago> math tutor ... angry It's not the same language, so why should he expect the semantics to be the same?
- JadeNB 6y ago> It's not the same language, so why should he expect the semantics to be the same? It's a bit like discovering that inline C in your favourite non-C language isn't actually semantically correct C. If you're a mathematician, then you know, intimately and fluently, how math is spoken and written, so seeing something that looks exactly like "inline math", but isn't, is jarring. (I don't get angry over it, but it is exactly counter to the extremely delicate and precise way mathematicians train ourselves to think about '='.)
- __ryan__ 6y agoI had the same issue. This is why I always comment my assignments. x = x + 1 // assign x to x+1
- xthestreams 6y agoI can't tell if this is a multiple joke or not