Skip to content

AnhelinaMikh/PythonCourses_Basic_for_backend

Repository files navigation

Python Courses: Basic for Backend

This repository contains my Python practice lessons.
Each folder represents a separate lecture with examples and exercises.


Lessons Overview

Lesson 1: Introduction

  • Topic: Typing, Variables, Strings, Numbers, Boolean Algebra, Branching
  • Folder: 1. Introduction. Typing. Variables. Strings and Numbers. Boolean Algebra. Branching
  • File: lection_1_python_2025.py
  • Description: Basics of Python, variables, strings, numbers, boolean logic, and conditional branching.

Lesson 2: Exception Handling, Lists, Strings, Slices, Loops

  • Topic: Exception Handling, Lists, Strings in Detail, Slices, Loops
  • Folder: 2. Exception Handling. Lists, Strings in Detail, Slices, Loops
  • Files:
    • lection_2_python_2025.py
    • practice.py
  • Description: Learn how to handle errors with try/except, work with lists and strings, understand slicing, and use loops in depth.

🧠 Practice Tasks

  1. Create a list numbers with numbers from 1 to 10.

    • Print each number squared.
    • Find the sum of all numbers.
  2. Create a string text and print each character in a loop.

  3. Use slices to print the first 5 and last 5 characters of text.

  4. Print numbers from 1 to 20 divisible by 3.

  5. Find the sum of numbers from 1 to 100 using a while loop.

  6. Create an infinite loop asking the user for a number and print its square.

    • Exit when the user enters 0 or exit.
  7. Print unique words from a list with duplicates.

  8. Ask the user for text and count vowels (a, e, i, o, u).

  9. Replace all occurrences of a word in a sentence with "replaced".

  10. Remove duplicates from a list without using sets.

  11. Find the smallest and largest number in a list without using built-in functions.

  12. Implement the FizzBuzz task:

    • Print numbers from 1 to n.
    • Replace multiples of 3 with "Fizz", 5 with "Buzz", and both with "FizzBuzz".

12.1 Make FizzBuzz dynamic — ask the user for both divisors and n.


How to Run a Lesson

  1. Open a terminal in the desired lesson folder.
  2. Run the Python file, for example:
    python lection_2_python_2025.py

About

This is my cource from backend

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages