{"id":20003210,"url":"https://github.com/mbrsagor/pythonnote","last_synced_at":"2025-03-02T00:24:24.559Z","repository":{"id":40954534,"uuid":"194315968","full_name":"mbrsagor/pythonNote","owner":"mbrsagor","description":"Study in python latest code and node serial","archived":false,"fork":false,"pushed_at":"2024-09-17T16:01:25.000Z","size":1384,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"master","last_synced_at":"2024-09-18T01:57:02.247Z","etag":null,"topics":["basic-programming","data-structures","mathematics","oop","python-library","python3"],"latest_commit_sha":null,"homepage":"https://github.com/mbrsagor/pythonNode3.7","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mbrsagor.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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,"publiccode":null,"codemeta":null}},"created_at":"2019-06-28T18:14:58.000Z","updated_at":"2024-09-17T16:01:29.000Z","dependencies_parsed_at":"2024-01-14T16:46:09.359Z","dependency_job_id":"4b0cd291-cadb-4570-87a1-2d4e2f48c7a5","html_url":"https://github.com/mbrsagor/pythonNote","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrsagor%2FpythonNote","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrsagor%2FpythonNote/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrsagor%2FpythonNote/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mbrsagor%2FpythonNote/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mbrsagor","download_url":"https://codeload.github.com/mbrsagor/pythonNote/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241441698,"owners_count":19963463,"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":["basic-programming","data-structures","mathematics","oop","python-library","python3"],"created_at":"2024-11-13T05:24:39.264Z","updated_at":"2025-03-02T00:24:24.517Z","avatar_url":"https://github.com/mbrsagor.png","language":"Python","readme":"# pythonNode\n\n\u003e In this series I'm sharing python basic to advance and data-structure code which I'm teaching my friends and brothers.\n\n#### Features\n\n- Python installation.\n- How to write python terminal or IDE.\n- Function.\n- Class (OOP).\n- Python library and modules.\n- Basic problem-solving.\n\n\n###### How to install python Linux (ubuntu) OS\n\nBy default Linux and Mac OS install python 2.7. If you install python3 or more version you may follow this commands.\n\n##### Optional, PATH environment\nSet up PATH environment variable, if you used HomeBrew to install Python3, then HomeBrew already added PATH. Do not \nchange PATH environment if you can launch python3 from terminal.\n\nAdd the following line to your `~/.profile` file\n\n`export PATH=/usr/local/bin:/usr/local/sbin:$PATH`\nUsually your Python installation directory looks like this, add it to your PATH\n\n`PATH=\"/Library/Frameworks/Python.framework/Versions/3.6/bin:${PATH}\"`\n\n##### On Linux/Ubuntu\n```\nsudo apt update\nsudo apt install software-properties-common\nsudo add-apt-repository ppa:deadsnakes/ppa\nsudo apt update\nsudo apt install python3.8\npython ––version\n```\n\n```python\nassert sum([1, 2, 3]) == 6, \"Should be 6\"\n```\n\n```python\nli = [5, 7, 22, 96, 54, 62, 77, 23, 73, 61]\nresult = list(filter(lambda x: x % 2 == 0, li))\nprint(result)\n\n```\n\n```python\n\nfrom extra import asyncio\n\n\nasync def say_hello():\n    print('Hello there,')\n    await asyncio.sleep(3)\n    print(f'This is Sagor')\n\n\n# asyncio.run(say_hello())\n\n\nasync def download():\n    for i in range(0, 11):\n        await asyncio.sleep(1)\n        print(f\"Download {i}% done\")\n    print(\"Thanks Sagor! Your download has been completed.\")\n\n\nasyncio.run(download())\n\n```\n\n\u003e Simple inner function example:\n\n```python\ndef select(num):\n    def child():\n        return \"Hello, I'm Mbr Sagor\"\n    \n    def child2():\n        return \"Hi, This is a Bozlur here.\"\n    \n    if num == 1:\n        return child()\n    else:\n        return child2()\n\n\nprint(select(1))\nprint(select(2))\n\n```\n\n###### Decorator is a one of the most common popular data structure in python. Below the simple example:\n```python\ndef uppercase_decorator(function):\n    def wrapper():\n        content = function().upper()\n        return content\n    return wrapper\n\n\n@uppercase_decorator\ndef say_hello():\n    return \"hello there, this is a bozlur rosid sagor\"\n\n\nprint(say_hello())\n```\n\n###### Static method and class Method example:\n```python\nclass User(object):\n\n    @classmethod\n    def get_full_name(cls, first_name, last_name):\n        print(f\"Full Name is: {first_name} {last_name}\")\n\n    @staticmethod\n    def get_name(name):\n        print(f\"Hello {name}\")\n\n\nif __name__ == '__main__':\n    User.get_full_name('mbr', 'sagor')\n    User.get_name('sagor')\n```\n\n\u003e About Me\n```python\nperson = {\n    'type': 'engineer',\n    'skills': ['Python', 'JavaScript','Django', 'FastAPI', 'Docker', 'AWS'],\n    'keepLearning': True\n}\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmbrsagor%2Fpythonnote","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmbrsagor%2Fpythonnote","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmbrsagor%2Fpythonnote/lists"}