[EDIT] and then there's "what is math?". The memorization from early grades that everyone shits on, with some simple algebra, is what I actually, ever, use in my life, plus some very basic geometry when doing stuff around the house. If it's for work it's some practical application thing. "Real" math like proofs? Never, ever.
Good remark. I wouldn't call arithmetic math, nor would I call using a Boolean expression math. I am currently working on a compiler bug that has to do with liveness analysis. That is an algorithm, which kind of is math, but the actual bug is just 'oh, for some reason the registers that the function arguments are passed in are not marked as live', and I wouldn't say that I had to use any math.
In my job, I'm usually either fixing bugs, parsing formats, making different API's work together by converting stuff or writing wrappers around API's. I wouldn't call any of this 'math', and if you'd ask me I have never used math at work (which is a shame really, because I really love math).
Can you share example code? I can't see how that works.
Restructuring code, for example, often needs a good grasp of negation in logic.
Do you need formal training to do it? Not really. It’s advantageous to have a good math grounding though. My colleagues that have a good math education can often reason and communicate using graph theory, especially when it comes to architecture. Set theory is also super useful - I’ll often see people writing crappy algorithms because they don’t know about using sets (again, understanding computability and complexity would have helped here).
Maths is all around us, it is really just the study of patterns after all. That applies more so in software, even if it’s not immediately apparent.
Basic arithmetic comes up all the time: pro-rating a monthly plan, figuring out how much to scale up or down a system in response to changes in data, figuring out when your system will run out of memory/disk.
Statistics and probability are also pretty common. I'm often calculating standard deviations and finding expected values of non uniform random variables. For example, how fast does a queue have to be to handle 1 second tasks 90% of the time, but 30 second tasks 10% of the time?
Derivatives comes with many graphics tasks, such as 3D graphics or animations.