{"id":18734910,"url":"https://github.com/1995parham-teaching/python101","last_synced_at":"2026-03-13T18:10:17.456Z","repository":{"id":93790094,"uuid":"35294337","full_name":"1995parham-teaching/python101","owner":"1995parham-teaching","description":"An Introduction to Python","archived":false,"fork":false,"pushed_at":"2024-04-04T06:22:42.000Z","size":9584,"stargazers_count":3,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-26T13:21:50.742Z","etag":null,"topics":["python-tutorial","python3","tex"],"latest_commit_sha":null,"homepage":"","language":"TeX","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/1995parham-teaching.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null}},"created_at":"2015-05-08T18:09:08.000Z","updated_at":"2023-07-30T06:40:08.000Z","dependencies_parsed_at":"2024-04-04T06:42:51.497Z","dependency_job_id":null,"html_url":"https://github.com/1995parham-teaching/python101","commit_stats":null,"previous_names":["1995parham-teaching/python101"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1995parham-teaching%2Fpython101","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1995parham-teaching%2Fpython101/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1995parham-teaching%2Fpython101/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/1995parham-teaching%2Fpython101/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/1995parham-teaching","download_url":"https://codeload.github.com/1995parham-teaching/python101/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248618277,"owners_count":21134200,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["python-tutorial","python3","tex"],"created_at":"2024-11-07T15:15:13.110Z","updated_at":"2026-03-13T18:10:17.450Z","avatar_url":"https://github.com/1995parham-teaching.png","language":"TeX","readme":"\u003ch1 align=\"center\"\u003e Python 101 \u003c/h1\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"banner\" src=\"./.github/assets/banner.png\" height=\"200px\" /\u003e\n  \u003cbr /\u003e\n  \u003cimg alt=\"GitHub Actions Workflow Status\" src=\"https://img.shields.io/github/actions/workflow/status/1995parham-teaching/python101/lint.yaml?style=for-the-badge\u0026logo=github\u0026label=lint\"\u003e\n  \u003cimg alt=\"GitHub Actions Workflow Status\" src=\"https://img.shields.io/github/actions/workflow/status/1995parham-teaching/python101/slides.yaml?style=for-the-badge\u0026logo=github\u0026label=slides\"\u003e\n\u003c/p\u003e\n\n## Introduction\n\nThis repository contains sample codes, presentation slides, and exercises for the Python 101 workshop.\nIt covers Python fundamentals from basic syntax to advanced topics like async programming and testing.\n\n**Online Slides:** [https://1995parham-teaching.github.io/python101/](https://1995parham-teaching.github.io/python101/)\n\n## Repository Structure\n\n```\npython101/\n├── src/                    # Python code examples\n│   ├── 01-basics/          # Variables, flow control, functions\n│   ├── 02-oop/             # Object-oriented programming\n│   ├── 03-advanced-oop/    # Metaclasses, MRO, descriptors\n│   ├── 04-functional/      # Functions, iterators, decorators\n│   ├── 05-io-files/        # File I/O, pickling\n│   ├── 06-networking/      # Socket programming\n│   ├── 07-memory/          # Garbage collection, references\n│   ├── 08-async/           # Async/await, asyncio\n│   ├── 09-libraries/       # Popular libraries (requests, pathlib)\n│   ├── 10-testing/         # pytest, mocking\n│   └── 11-typing/          # Type hints, generics, dataclasses\n├── slides/                 # Marp markdown slides\n└── .github/workflows/      # CI/CD workflows\n```\n\n## Course Curriculum\n\n### Week 1-2: Python Fundamentals\n\n- Basic syntax and data types\n- Flow control (if/else, loops)\n- Functions and lambda expressions\n- Object-oriented programming\n- Classes, inheritance, and MRO\n\n**Examples:** `src/01-basics/`, `src/02-oop/`, `src/03-advanced-oop/`\n\n### Week 3: Libraries \u0026 Async Programming\n\n- File I/O and pathlib\n- Working with JSON\n- HTTP requests with `requests` library\n- Async programming with `asyncio`\n\n**Examples:** `src/05-io-files/`, `src/08-async/`, `src/09-libraries/`\n\n### Week 4: Best Practices\n\n- Testing with pytest\n- Type hints and mypy\n- Code quality tools (ruff, black)\n- Design patterns\n\n**Examples:** `src/10-testing/`, `src/11-typing/`\n\n## Getting Started\n\n### Prerequisites\n\n- Python 3.10 or higher\n- [uv](https://docs.astral.sh/uv/) (Python package manager)\n\n### Setup\n\n```bash\n# Clone the repository\ngit clone https://github.com/1995parham-teaching/python101.git\ncd python101\n\n# Install dependencies (uv handles the virtual environment)\nuv sync --all-extras\n```\n\n### Running Examples\n\nEach Python file in `src/` is self-contained and can be run directly:\n\n```bash\nuv run python src/01-basics/flow-control.py\nuv run python src/04-functional/iterators.py\n```\n\n### Running Tests\n\n```bash\n# Run tests (pytest is included in dev dependencies)\nuv run pytest src/10-testing/ -v\n```\n\n## Building Slides\n\n### Marp Slides (HTML)\n\n```bash\n# Install Marp CLI\nnpm install -g @marp-team/marp-cli\n\n# Build all slides\nfor file in slides/*.md; do\n  marp \"$file\" --html\ndone\n```\n\n## Presented At\n\n- 7th Amirkabir Linux Festival -- 2015\n- [Diginext Software Engineering Bootcamp](https://diginext.ir/academy/software-engineering-bootcamp) -- 2023\n  - Monday, August 14, 2023 -- 18:00 - 20:30\n  - Saturday, August 19, 2023 -- 18:00 - 20:30\n  - Monday, August 21, 2023 -- 18:00 - 20:30\n  - Saturday, August 26, 2023 -- 18:00 - 20:30\n  - Monday, August 28, 2023 -- 18:00 - 20:30\n  - Saturday, September 2, 2023 -- 18:00 - 20:30\n\n## Contributing\n\nThank you for your interest in contributing to Python 101! This section provides guidelines for contributing to this educational repository.\n\n### Ways to Contribute\n\n#### 1. Improve Existing Examples\n\n- Fix bugs or typos in code examples\n- Add clearer comments or explanations\n- Improve docstrings and documentation\n- Add expected output comments\n- Create additional exercises\n\n#### 2. Add New Content\n\n- New code examples demonstrating Python concepts\n- Additional slides for topics not covered\n- Translations of existing content\n\n#### 3. Report Issues\n\n- Report bugs in code examples\n- Suggest improvements or clarifications\n- Request new topics to be covered\n\n### Fork and Clone\n\n```bash\n# Fork the repository on GitHub, then clone your fork\ngit clone https://github.com/YOUR_USERNAME/python101.git\ncd python101\n\n# Add upstream remote\ngit remote add upstream https://github.com/1995parham-teaching/python101.git\n```\n\n### Set Up Development Environment\n\n```bash\n# Install development dependencies (uv handles the virtual environment)\nuv sync --all-extras\n```\n\n### Create a Branch\n\n```bash\ngit checkout -b feature/your-feature-name\n```\n\n### Code Guidelines\n\n#### Python Code Style\n\n- Follow [PEP 8](https://pep8.org/) style guidelines\n- Use meaningful variable and function names\n- Add type hints where appropriate\n- Include docstrings for modules, classes, and functions\n\n#### Example File Template\n\nEach Python file should follow this structure:\n\n```python\n\"\"\"\nTopic: [Topic Name]\nConcepts: [comma-separated list of concepts]\nLearning objectives:\n    - [Objective 1]\n    - [Objective 2]\n\nAuthor: [Your name] ([your email])\n\"\"\"\n__author__ = \"[Your name]\"\n\n# ... code ...\n\n# === Expected Output ===\n# [Expected output as comments]\n\n# === Exercises ===\n# 1. [Exercise 1]\n# 2. [Exercise 2]\n```\n\n#### Commit Messages\n\n- Use clear, descriptive commit messages\n- Start with a verb (Add, Fix, Update, Remove)\n- Reference issues when applicable\n\n```\nAdd async HTTP example with aiohttp\n\n- Demonstrates concurrent URL fetching\n- Includes error handling pattern\n- Closes #123\n```\n\n### Testing\n\nBefore submitting, ensure your code works:\n\n```bash\n# Run the Python file\nuv run python src/path/to/your-file.py\n\n# If adding tests, run pytest\nuv run pytest src/10-testing/ -v\n\n# Check types (if applicable)\nuv run mypy src/path/to/your-file.py\n```\n\n### Submitting Changes\n\n1. Push your branch to your fork\n2. Create a Pull Request against the `main` branch\n3. Provide a clear description of your changes\n4. Wait for review and address any feedback\n\n### Slide Contributions\n\n#### Marp Slides\n\nSlides are written in Markdown using [Marp](https://marp.app/).\n\n```markdown\n---\nmarp: true\ntheme: default\npaginate: true\nheader: \"Python 101\"\nfooter: \"Topic Name\"\n---\n\n# Slide Title\n\nContent here...\n\n---\n\n## Next Slide\n\nMore content...\n```\n\n#### Building Slides Locally\n\n```bash\nnpm install -g @marp-team/marp-cli\nmarp slides/your-slide.md --html\n```\n\n### Questions?\n\nIf you have questions about contributing, please:\n\n1. Check existing issues and pull requests\n2. Open a new issue for discussion\n3. Ask in the pull request\n\nThank you for helping improve Python education!\n\n## Special Thanks To\n\n- [Dr.Bakhshi](https://github.com/Bahador-Bakhshi) (Helped in holding classes)\n- [Dr.Payberah](https://github.com/payberah) (Contributed to creating slides)\n- [S.M.M.Ahmadpanah](https://github.com/smahmadpanah) (Contributed to editing slides)\n- [E.Jalalpour](https://github.com/eljalalpour) (Contributed to editing slides)\n\n## License\n\nThis project is licensed under the Apache 2.0 License - see the [LICENSE](LICENSE) file for details.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F1995parham-teaching%2Fpython101","html_url":"https://awesome.ecosyste.ms/projects/github.com%2F1995parham-teaching%2Fpython101","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2F1995parham-teaching%2Fpython101/lists"}