If coding tutorials with math examples are the bane of your existence, keep reading. This series uses relatable examples like dogs and cats.
I have experience with Python, but saw this 30 day challenge and decided it could only help.
Link: Day 1 content
Note: This challenge was built to be beginner friendly and help people learn Python.
- installing python
- a simple script in IDLE
- addressing a syntax error
- math operators
- installing VS Code
- starting with VS Code
- Data Types
link to day 1 material
a = 3 b = 4 print(a + b) # 3 + 4 = 7
a = 3 b = 4 print(a - b) # 3 - 4 = -1
a = 3 b = 4 print(a * b) # 3 * 4 = 12
a = 3 b = 4 print(a / b) # 3 / 4 = .75
a = 3 b = 4 print(a ** b) # 3 ** 4 = 81
** is taking care of the exponent. If broken down it would look like
3 * 3 * 3 * 3
a = 10 b = 3 print(a % b) # modulo 10 % 3 = 1
Use this operator if you only want the remainder or whats left over after the division. In this example, we've done
10 / 3 which give us 3 groups of 3 and a remainder of 1.
This could be used dividing time. You can use the remainder for the next smaller unit of time.
a = 10 b = 3 print(a // b) # floor division 10 // 3 = 3
This is important to use when you can only have whole things. For example you can't have .5 of a person or .2 of a plane. So, you would round down so you're only using whole people and whole planes.
|Boolean||True or False||
|String||characters in quotes||
|List||in order; may have different data types||
|Tuple||cannot be changed||
|Set||may only have unique elements and may store different data types||My name is Vicki, but a set would be
Series based on