Overclock.net - An Overclocking Community - View Single Post - Why is this correct? Looks to me like it shouldn't work.

View Single Post
post #4 of (permalink) Old 10-23-2017, 07:26 PM
New to Overclock.net
ltpdttcdft's Avatar
Join Date: Jun 2013
Posts: 587
Rep: 36 (Unique: 30)
To be clear, I was evaluating the expression, not writing another script. Basically the "show your work" for a math problem. (Nothing wrong with using paper, I find that it helps me a lot if I write things down on paper first, maybe outline what I'm trying to do in flowcharts/pseudocode before jumping in and coding.)

The stuff on the right of the equal sign is all treated as numbers first, and the expression is evaluated.
Then the result is assigned to the variable to the left of the equals sign.

Be careful with dollar signs, many programming languages treat it as a special character for different things.

ltpdttcdft is offline