Skip to content

Beginner-friendly Python code examples and exercises – a strong foundation for aspiring data analysts.

Notifications You must be signed in to change notification settings

Ishmal793/Basic-Python-

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 

Repository files navigation

Basic-Python-

🐍 Python Basics – Beginner Level

This repository contains Python basics that cover all the essential topics for absolute beginners in programming. These notes and code examples are designed to help you understand the building blocks of Python, which is the backbone of Data Analytics and Data Science.

📌 Description

When I first started learning Python, I created this notebook to understand and practice fundamental concepts. Today, whenever I revisit this code, it helps me revise and refresh my Python basics — and I hope it does the same for you!

📁 You can find the complete notebook with working code here:
👉 GitHub Repository


📖 Topics Covered

1. Print Statement

  • Using 'single', "double", and '''triple''' quotes
  • Printing strings, numbers, and special characters

2. Comments

  • Single-line comments using #
  • Multi-line comments using ''' ''' or """ """

3. Variables

  • Naming conventions
  • Assigning different types of values
  • Case sensitivity

4. Data Types & User Input

  • Input from user using input()
  • Type conversion with int(), float(), and eval()
  • Using type() to identify data types

5. Type Casting

  • Implicit and Explicit conversions
  • Converting between strings, integers, and floats

6. Operators

  • Arithmetic: +, -, *, /, //, %, **
  • Comparison: ==, !=, <, >, <=, >=
  • Logical: and, or, not
  • Assignment: =, +=, -=, etc.
  • Identity: is, is not
  • Membership: in, not in
  • Bitwise: &, |, ^, ~, <<, >>

7. Conditional Statements

  • if, else, elif
  • Nested if statements
  • Short-hand if and if-else

💡 Problem Solving Practice

  • Displaying a person’s name, age, and address
  • Swapping variables (two methods)
  • Converting float to integer
  • Creating a student ID card form
  • Type conversions from int to float
  • Checking if number is positive or negative
  • Odd or even number checker
  • Area calculator (circle, rectangle, triangle)
  • Vowel checker
  • Digit count checker (1–5 digits)

🎯 Why This Matters?

Python is the backbone of modern Data Analytics. Mastering these basics builds a strong foundation for advanced libraries like NumPy, Pandas, and tools like Power BI, SQL, and Excel. This is a part of my learning journey, and I'm sharing it to help others who are just starting.


🔗 Connect With Me

Feel free to explore the code and star the repo if you find it helpful ⭐

📂 Folder Structure

📁 python-basics/
│
├── python_basics.ipynb    # Jupyter Notebook with all examples and problems
├── README.md              # You’re here!

About

Beginner-friendly Python code examples and exercises – a strong foundation for aspiring data analysts.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published