Python Programming for Beginners Crash Course with Hands-On Exercises, Including NumPy, Pandas and Matplotlib
()
About this ebook
Are you ready to start your path to becoming a Python programmer?
Are you looking for the best Python Crash Course to Learn Python Coding fast, simply and efficiently?
If yes, then this book is for you. This is one of the most comprehensive and straight-forward guides to master the Python programming language.
This book is designed for both beginners with little to no Python programming experience and experienced Python developers looking to make it into the world of Data Science!
This is a complete book for Python beginners with all the concepts and the opportunity to apply your knowledge thoroughly! Exercises and examples are included for learning the concepts fast and easily, as well as the results of the examples are also added.
This book is divided into 4 units.
In the first unit, we'll study a brief introduction to Python programming language, including variables, user input, arithmetic operations, comparison and logical operators, decision making statements, loops, functions, lists, tuples and dictionary.
In the second unit, we'll study NumPy, including NumPy arrays, different mathematical operations, array sorting, indexing and slicing techniques.
In the third unit, we'll study Pandas, including Pandas series, DataFrame, operations, importing and exporting data.
In the fourth unit, we'll study Matplotlib, including Matplotlib plots, markers, lines, grids, labels, subplots, scatter plots, bar graphs, histograms, and pie charts.
What are you waiting for? Start your Python journey today and let's start coding!
Ibnul Jaif Farabi
Ibnul Jaif Farabi is a Web Designer and Developer, UI / UX and Mobile App Developer based in New York City. He has a wide depth of knowledge and expertise in using his technical skills in the fields of electrical engineering, computer science and software development to help organizations increase productivity, as well as accelerating business performance. He also has a deep passion for troubleshooting technical issues and brainstorming new ideas that can lead to unique solutions. He works effectively and efficiently as a team player as well as being purpose driven and result oriented.
Read more from Ibnul Jaif Farabi
Learn HTML and CSS In 24 Hours and Learn It Right | HTML and CSS For Beginners with Hands-on Exercises Rating: 0 out of 5 stars0 ratingsLearn Salesforce Lightning Administrator For Beginners Certification Guide | Configuration and Setup Rating: 0 out of 5 stars0 ratings
Related to Python Programming for Beginners Crash Course with Hands-On Exercises, Including NumPy, Pandas and Matplotlib
Related ebooks
Conceptual Programming: Conceptual Programming: Learn Programming the old way! Rating: 0 out of 5 stars0 ratingsComputer Programming The Doctrine Rating: 0 out of 5 stars0 ratingsProblem Solving in C and Python: Programming Exercises and Solutions, Part 1 Rating: 5 out of 5 stars5/5Javascript Concepts: 1St Edition Rating: 0 out of 5 stars0 ratingsComputer Programming JavaScript, Python, HTML, SQL, CSS Rating: 0 out of 5 stars0 ratingsPython Programming for Beginners: A guide to Python computer language, computer programming, and learning Python fast! Rating: 0 out of 5 stars0 ratingsAutoIT Scripting For Beginners Rating: 5 out of 5 stars5/5Learn Programming by Coding Like a Professional: Create Games, Apps, & Programs Rating: 0 out of 5 stars0 ratingsHandbook of Python: Easy to Carry Python Basics Rating: 0 out of 5 stars0 ratingsPython: Tips and Tricks to Programming Code with Python: Python Computer Programming, #3 Rating: 5 out of 5 stars5/5Ian Talks Python A-Z Rating: 0 out of 5 stars0 ratingsPython: Programming For Intermediates: Learn The Basics Of Python In 7 Days! Rating: 0 out of 5 stars0 ratingsPython: Beginner's Guide to Programming Code with Python Rating: 0 out of 5 stars0 ratingsPython for Beginners: Learn It as Easy as Pie Rating: 0 out of 5 stars0 ratingsPython. Easy Steps to Learning. Rating: 0 out of 5 stars0 ratingsLearn AI-assisted Python Programming: With GitHub Copilot and ChatGPT Rating: 0 out of 5 stars0 ratingsPython: Advanced Guide to Programming Code with Python Rating: 0 out of 5 stars0 ratingsASP.NET AJAX The Ultimate Step-By-Step Guide Rating: 0 out of 5 stars0 ratingsNew Learning of Python by Practical Innovation and Technology Rating: 0 out of 5 stars0 ratingsProfound Python Rating: 5 out of 5 stars5/5Getting Started with Bootstrap 3.2 Rating: 0 out of 5 stars0 ratingsJob Ready Go Rating: 0 out of 5 stars0 ratingsPython Networking 101: Navigating essentials of networking, socket programming, AsyncIO, network testing, simulations and Ansible Rating: 0 out of 5 stars0 ratingsLearn PHP 8: Using MySQL, JavaScript, CSS3, and HTML5 Rating: 0 out of 5 stars0 ratingsJava Programming : The Complete Beginners Guide Rating: 0 out of 5 stars0 ratingsLearning Rust Rating: 0 out of 5 stars0 ratings
Programming For You
Learn to Code. Get a Job. The Ultimate Guide to Learning and Getting Hired as a Developer. Rating: 5 out of 5 stars5/5Coding All-in-One For Dummies Rating: 4 out of 5 stars4/5Python Programming : How to Code Python Fast In Just 24 Hours With 7 Simple Steps Rating: 4 out of 5 stars4/5PYTHON: Practical Python Programming For Beginners & Experts With Hands-on Project Rating: 5 out of 5 stars5/5Grokking Algorithms: An illustrated guide for programmers and other curious people Rating: 4 out of 5 stars4/5Learn SQL in 24 Hours Rating: 5 out of 5 stars5/5Excel : The Ultimate Comprehensive Step-By-Step Guide to the Basics of Excel Programming: 1 Rating: 5 out of 5 stars5/5SQL QuickStart Guide: The Simplified Beginner's Guide to Managing, Analyzing, and Manipulating Data With SQL Rating: 4 out of 5 stars4/5HTML & CSS: Learn the Fundaments in 7 Days Rating: 4 out of 5 stars4/5Java for Beginners: A Crash Course to Learn Java Programming in 1 Week Rating: 5 out of 5 stars5/5Web Designer's Idea Book, Volume 4: Inspiration from the Best Web Design Trends, Themes and Styles Rating: 4 out of 5 stars4/5Learn PowerShell in a Month of Lunches, Fourth Edition: Covers Windows, Linux, and macOS Rating: 0 out of 5 stars0 ratingsRaspberry Pi Cookbook for Python Programmers Rating: 0 out of 5 stars0 ratingsPython QuickStart Guide: The Simplified Beginner's Guide to Python Programming Using Hands-On Projects and Real-World Applications Rating: 0 out of 5 stars0 ratingsPython: For Beginners A Crash Course Guide To Learn Python in 1 Week Rating: 4 out of 5 stars4/5Python Data Structures and Algorithms Rating: 5 out of 5 stars5/5OneNote: The Ultimate Guide on How to Use Microsoft OneNote for Getting Things Done Rating: 1 out of 5 stars1/5Poirot's Early Cases Rating: 5 out of 5 stars5/5The Little SAS Book: A Primer, Sixth Edition Rating: 5 out of 5 stars5/5Learn JavaScript in 24 Hours Rating: 3 out of 5 stars3/5Python Machine Learning By Example Rating: 4 out of 5 stars4/5
Reviews for Python Programming for Beginners Crash Course with Hands-On Exercises, Including NumPy, Pandas and Matplotlib
0 ratings0 reviews
Book preview
Python Programming for Beginners Crash Course with Hands-On Exercises, Including NumPy, Pandas and Matplotlib - Ibnul Jaif Farabi
Table of Contents
Unit 01: Python Programming
Unit 02: NumPy
Unit 03: Pandas
Unit 04: Matplotlib
Unit 01: Python Programming
Introduction to Python
What is Python programming language?
Python is a high-level programming language that uses a pre-defined set of instructions to teach a computer to perform certain tasks. Python is a free and open-source programming language. It was developed by Guido van Rossum in 1991. Anyone can read, develop, modify and distribute the code of the Python scripts.
In this book, we’re going to use Python 3, which is the latest version of Python.
We’re going to use JupyterLab for the Python programming.
We can install JupyterLab by running the following command in the terminal.
pip install jupyterlab
Text, logo Description automatically generatedNow, we’re going to write our first program. We want to display "Hello World" as the output. For this, we need to use the print() statement. print() is a built-in function that can be used to display stuff on the output screen. And whatever we would like to display, needs to be inside the parenthesis and enclosed within the double quotes
.
Code:
print(Hello World
)
Output:
Hello World
Graphical user interface Description automatically generated with medium confidenceYay! We’ve just written our first Python program.
Now, let’s talk about the comments in Python. Comments are small pieces of code which will be ignored by the Python interpreter. It makes the code easier to understand. Anything written after the # symbol is considered a comment in Python. Now, we’ll add a comment on the above program.
Code:
#This is our first Hello World program.
print(Hello World
)
Output:
Hello World
Graphical user interface, text Description automatically generated with medium confidenceVariables in Python
In python, the variables are used as containers to store the values. The values can be numbers, or text. Variables are identified by their variable names.
variable_01 = 752
Here, "variable_01 is the name of the variable,
= is the assignment operator,
752" is the value that needs to be assigned to the variable. So, variable_01 has a value of 752.
Types of variables:
String Types: When the variable contains texts or words in general, it’s called the String variable. A String is a sequence of characters and are enclosed within the double quotes
or single quotes ‘ ’.
my_city_01 = New York
Here, my_city_01 is a string with the value "New York".
my_city_02 = 64532745
Here, my_city_02 is a string with the value "64532745. As
64532745 is written inside the double quotes
" it’s considered a string.
Numeric Types: There’re two types of numeric data types in Python; Integer and Float. Here, the value of the variable will always be a number.
If the number doesn’t have a decimal value, it’s an Integer. 5, 65, 124 etc. are Integers.
number_of_planets = 9
If the number has a decimal value, it’s Float. 1.25, 243.96 34.26 etc. are Float numbers.
human_body_temperature = 98.4
Note that Python automatically identifies the type from the values, so we don’t need to specify the type manually in the program.
Boolean Types: A variable where the value can be either True or False, is called the Boolean type of variable.
variable_boolean_01 = True
variable_boolean_02 = False
Code:
#String type of variable
my_city_01 = New York
my_city_02 = 64532745
print(my_city_01)
print(my_city_02)
#Numeric type of variable
#Integer
number_of_planets = 9
print(number_of_planets)
#Float
human_body_temperature = 98.4
print(human_body_temperature)
#Boolean type of variable
variable_boolean_01 = True
variable_boolean_02 = False
print(variable_boolean_01)
print(variable_boolean_02)
Output:
New York
64532745
9
98.4
True
False
Graphical user interface, text Description automatically generatedHow to Take the User Input in Python
To get the input from the user in Python, we need to use the input() function. We can also add more information inside the parenthesis.
location_name = input("Where