Originally Posted by PhotonFanatic
I was more wondering how a string could equal a number, not really about the math itself. My question would be something like: How does 4 == "Cheeseburger". Now you can say that you've got 4 cheeseburgers, but I was thinking that to say that you should be using a variable. cheeseburger = 4. You gotta remember I'm brand new to this, I have only finished 30% of an online course. Advanced mathematics don't really enter into it at this point.
Not that I'm bad at math, I've always felt like I was pretty good at it. I'm way out of practice for sure. But I may take some math classes and logic if I feel the need. Depends on what I run into on the job, once I'm done with code academy, have taken the python course/s at the local college, and have gotten certified. Then I'll look at what other improvements can be made to make me a top tier programmer.
Although I will say, that most of the old hand programmers I've talked to (when determining if I wanted to learn) mirror deepor on this. The general sentiment seems to be, that yeah its helpful but not some kind of big deal.
Anything can equal anything depending on how they are compared. A string is a combination of chars. A char has an int value. Therefore each letter has a numeric value and a string can have a numeric value.