PYTHON FOR NEWBIES
Leah Ndirangu
Posted on February 14, 2022
GETTING STARTED
Python programming language is a high-level, general purpose language. It is written in human readable language and designed to solve a particular problem.
Python is suitable for but not limited to:
- Web Development
- Data Science
- Machine Learning
- Game Development
- Data Engineering
- Robotics
- Automation
INSTALLING PYTHON
To install python visit: Python, scroll down to active releases to see which version is secure for download.
NOTE:
Python 2.7 is no longer in use.
Once you've settled on a specific version, select download to download
Take note of the operating system your machine uses before download.
Python on visual-studio and pycharm:
To get started with Python on Visual Studio, follow Getting Started with Python in VS Code and pycharm Get Started
WRITING YOUR FIRST PROGRAM
Python uses print function to output text. Print must be followed by a parenthesis which encloses the output we want to generate.
Arithmetic operators
Operator | Description | Syntax |
---|---|---|
+ | Addition | a+b |
- | Subtraction | a-b |
* | Multiplication | a*b |
/ | Division | a/b |
% | Modulus | a%b |
// | Quotient | a//b |
** | Exponent | a**b |
Example:
Logic Operators
Operator | Description | Syntax |
---|---|---|
and | True if both operands result is true | a and b |
or | True if either operands result is true | a or b |
not | True if both operands result is false | a not b |
REFERENCES
Python.org/downloads/
Jetbrains.com
visualstudio.com/docs/python/python-tutorial
Posted on February 14, 2022
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.