r/CodingForBeginners • u/darksllmm • 1d ago
math in coding
hello everyone im about to start learning to code (python specifically) and i want to learn the math i would need for it first to make the learning process a bit easier.
any pointers would be greatly appreciated
thx for the help
6
Upvotes
3
u/BobCorndog 1d ago
You don’t really need math knowledge unless you do stuff that involves math
2
u/shailendra_codes 1d ago
Great news: to start learning Python, you do **not** need advanced math at all! Basic school-level arithmetic (`+`, `-`, `*`, `/`) and simple comparison logic (`>`, `<`, `==`) are more than enough to get started.
Here is the only math you actually need early on:
You only need higher math (like linear algebra or calculus) much later if you decide to go into AI/Machine Learning or 3D game physics. Start coding right away—you will pick up the math naturally as you build small projects! 🙌
3
u/mjmvideos 1d ago
Really, the math comes with the domain area you are programming for. The language itself requires no math at all. Though an understanding of addition is helpful in working with loops.
1
u/ninhaomah 1d ago
Start with basic Python first.
1
u/Top_Finger_909 1d ago
You do not need to know much “math” to code however if you’re intent is learning data structures and algorithms then you will need:
1.) Discrete Math: https://personal.math.ubc.ca/~PLP/book/frontmatter.html
2.) Algorithms: https://theswissbay.ch/pdf/Gentoomen%20Library/Algorithms/Algorithm%20Design%20-%20John%20Kleinberg%20-%20Éva%20Tardos.pdf
Id highly recommend starting with something like the discrete math book up top. Then the algorithm design manual by Steven Skiena, then once you are comfortable do one of Kleinberg and Tardos or CLRS (only read specific sections)
This is about as “math” heavy things can get although again you don’t need strictly need all of this
1
u/cvco210 1d ago
You don’t need to study math to learn how to code. Just start coding
1
u/wak_trader 1d ago
It really dependson what you want to do. Linear algebra understanding will be essential after a certain point for a lot of hte paths available.
1
u/dld2517 1d ago
Math for Programmers (No Starch Press).
1
u/RedAndBlack1832 1d ago
"Math" in terms of like classroom study is very domain specific. Knowing powers of two and modular arithmetic is generally helpful though. Abstractly, the "math" is more about logic and procedural thinking. Breaking things up into steps with intermediate results and representing systems as functions (the math term, not the programming term) that feed into each other.
1
u/Jeremi360 1d ago
Coding is more logic then math, you only need math for math things,
you only need to know that: `con`, `sin`, `tan`, etc. exist and when to use it,
you don't need to write them by hand or how they work under the hood.
1
u/SeaTeaching3550 1d ago
what do you exactly want to do using python ? if its AI/ML or data science, then maths is much needed otherwise you dont need maths. basic maths which i am sure you know, is more than enough for programming stuff.
But if you are planning to learn ML, you need statistics, calculus, linear algebra, probability etc
1
u/Hot_Dog2376 1d ago
General purpose? Linear Algebra. Vectors help a lot for things that you don't even think they would at first.
Discreet number theory if you really wanna get into it.
1
u/JGhostThing 21h ago
I find that I used basic algebra, calculus, and trigonometry. There are some subjects that I would have liked to have known linear algebra, such as computer graphics and such.