Computer Science Canada Can someone help explain "=" and ":=? |
Author: | jeffery1204 [ Sun Dec 14, 2014 8:23 pm ] |
Post subject: | Can someone help explain "=" and ":=? |
When programing, i m always confused when to use "=" or ":=" what does ":" this do? |
Author: | Zren [ Sun Dec 14, 2014 9:15 pm ] | ||
Post subject: | RE:Can someone help explain "=" and ":=? | ||
They're different operators. := is an assignment operator. Where you assign a value to a variable. = is a comparison operator. Where you compare to see if the left side value equals the right side value.
Quote: what does ":" this do?
With it there, it's the assignment operator. Without it, it's a comparison operator. It basically boils down to what "keyword" the guys who made the Turing language decided to use to represent the different operators. It's like the difference between the word "a" and the word "at". |