logoalt Hacker News

p0w3n3dyesterday at 7:45 PM1 replyview on HN

On my CS lectures algorithms professor used this pseudo language when writing an algorithm on a whiteboard :

  I <- I++
On the next hour another professor was giving lecture on C++ programming. I asked him the question: what would happen if we compiled

  i = i++

He went into some deep elaboration on it, but reassumed that only idiot would write like this...

Replies

mywittynameyesterday at 8:49 PM

Out of curiosity, I checked if gcc would optimize i = i++ out, and it does!