Keep Scrolling Down to See the Answer...
Keep Scrolling Down to See the Answer...
The Interactive Ruby Shell Says the Answer is 12
>> 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 * 0 + 1
=> 12
The Bash Shell Says the Answer is 12
$ let "x = 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 + 1 * 0 + 1";echo $x
12
Lex's Fancy Calculator App Says the Answer is 12
And my calculator application running in the iPhone Simulator is always right!
Conclusion
It's tempting the to use the old rule from grade school: Anything multiplied by 0 is 0 and add 1 to it to arrive at 1.However, you'd be forgetting the rule of operator precedence, which says that given a series of addition and multiplication operations, perform the multiplication operation(s) first and then perform the addition. So, multiply this (1 * 0) to get 0. Then add up all the other 1's and you get 12.
Nice Articles!
ReplyDeleteGreat moments of this articles!
Im surprised! Keep posting dude!
Read More:
* Download Film Minions 3 (Subtitle Indonesia) 2015
* Download Yakuza Apocalypse Subtitle Indo (2015)
* Download Film Terminator Genisys 2015 (Subtitle Indonesia)
* Download Film Insidious: Chapter 3 2015 (Subtitle Indonesia)
* Download Inside Out 2015 (Subtitle Indonesia) HD-RAY
* Download Jurassic World 2015 (Subtitle Indonesia)
* Film Korea Romantis Populer 2015