Top Related Projects
Python extension for Visual Studio Code
The Python micro framework for building web applications.
The Web framework for perfectionists with deadlines.
The fundamental package for scientific computing with Python.
Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more
scikit-learn: machine learning in Python
Quick Overview
The microsoft/c9-python-getting-started repository is a comprehensive learning resource for Python beginners. It contains a series of lessons, code samples, and exercises designed to introduce fundamental Python concepts and programming practices. The repository is part of Microsoft's Channel 9 Python for Beginners video series.
Pros
- Well-structured content with clear progression from basic to more advanced topics
- Includes practical exercises and code samples to reinforce learning
- Aligned with a video series, providing multiple learning formats
- Covers a wide range of Python topics, including data structures, functions, and modules
Cons
- May not be suitable for experienced Python developers looking for advanced content
- Some content might become outdated as Python evolves
- Lacks in-depth coverage of more complex topics like web development or data science
- Limited interactivity compared to dedicated online learning platforms
Code Examples
This repository is not a code library but a learning resource. Therefore, code examples are not applicable in the context of using the repository as a library. However, the repository itself contains numerous code examples for learning purposes.
Getting Started
To get started with this learning resource:
-
Clone the repository:
git clone https://github.com/microsoft/c9-python-getting-started.git
-
Navigate to the cloned directory:
cd c9-python-getting-started
-
Explore the lessons in the
lessons
directory and follow along with the corresponding video series on Channel 9. -
Complete the exercises in the
exercises
directory to practice your skills. -
Refer to the
README.md
file in each section for additional guidance and resources.
Competitor Comparisons
Python extension for Visual Studio Code
Pros of vscode-python
- More comprehensive Python development environment with advanced features like debugging, linting, and IntelliSense
- Regularly updated with new features and improvements
- Larger community and more extensive documentation
Cons of vscode-python
- Steeper learning curve for beginners due to its extensive feature set
- Requires more system resources compared to simpler Python environments
Code Comparison
vscode-python:
import sys
def greet(name):
print(f"Hello, {name}!")
if __name__ == "__main__":
greet(sys.argv[1])
c9-python-getting-started:
name = input("What's your name? ")
print(f"Hello, {name}!")
The vscode-python example demonstrates a more structured approach with command-line argument handling, while c9-python-getting-started focuses on basic input/output for beginners.
vscode-python is better suited for experienced developers working on larger projects, offering a wide range of tools and extensions. c9-python-getting-started is ideal for newcomers to Python, providing a simpler environment to learn the basics without overwhelming features.
The Python micro framework for building web applications.
Pros of Flask
- More comprehensive web framework with built-in routing, templating, and request handling
- Larger community and ecosystem with extensive third-party extensions
- Better suited for building full-fledged web applications
Cons of Flask
- Steeper learning curve for beginners compared to c9-python-getting-started
- Requires more setup and configuration for basic projects
- May be overkill for simple scripts or small-scale applications
Code Comparison
Flask example:
from flask import Flask
app = Flask(__name__)
@app.route('/')
def hello_world():
return 'Hello, World!'
c9-python-getting-started example:
print("Hello, World!")
Summary
Flask is a powerful web framework for building Python web applications, while c9-python-getting-started is a beginner-friendly introduction to Python basics. Flask offers more features and flexibility for web development but may be more complex for newcomers. c9-python-getting-started provides a simpler entry point for learning Python fundamentals but is limited in scope for web development.
The Web framework for perfectionists with deadlines.
Pros of Django
- Comprehensive web framework with built-in features for rapid development
- Large, active community with extensive documentation and third-party packages
- Robust ORM for database management and migrations
Cons of Django
- Steeper learning curve for beginners compared to simpler tutorials
- More complex setup and configuration process
- Potentially overkill for small, simple projects
Code Comparison
Django (urls.py):
from django.urls import path
from . import views
urlpatterns = [
path('', views.index, name='index'),
path('about/', views.about, name='about'),
]
c9-python-getting-started (app.py):
from flask import Flask, render_template
app = Flask(__name__)
@app.route('/')
def index():
return render_template('index.html')
The Django code demonstrates URL routing using the built-in path
function, while the c9-python-getting-started example uses Flask's decorator-based routing. Django's approach is more structured and scalable for larger projects, but Flask's simplicity may be preferable for beginners or smaller applications.
The fundamental package for scientific computing with Python.
Pros of NumPy
- Extensive library for scientific computing with powerful array operations
- Highly optimized C implementations for numerical algorithms
- Large community and ecosystem of related scientific Python libraries
Cons of NumPy
- Steeper learning curve for beginners
- More complex installation process, especially on Windows
- Not focused on general Python programming concepts
Code Comparison
c9-python-getting-started:
# Basic list operations
fruits = ["apple", "banana", "cherry"]
print(fruits[0])
fruits.append("date")
NumPy:
import numpy as np
# Array operations
arr = np.array([1, 2, 3, 4])
print(arr * 2) # Element-wise multiplication
print(np.sum(arr)) # Sum of all elements
Summary
c9-python-getting-started is designed for Python beginners, offering a gentle introduction to basic concepts. It's easier to set up and provides a broad overview of Python programming.
NumPy, on the other hand, is a specialized library for numerical computing. It offers powerful tools for scientific and mathematical operations but requires more advanced Python knowledge. NumPy is essential for data science and scientific computing but may be overwhelming for those just starting with Python.
Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more
Pros of pandas
- Extensive data manipulation and analysis capabilities
- Large, active community with frequent updates and improvements
- Comprehensive documentation and extensive ecosystem of related tools
Cons of pandas
- Steeper learning curve for beginners
- Higher resource consumption for large datasets
- More complex setup and installation process
Code Comparison
c9-python-getting-started:
# Basic list manipulation
fruits = ["apple", "banana", "cherry"]
print(fruits[1])
pandas:
import pandas as pd
# DataFrame manipulation
df = pd.DataFrame({"fruits": ["apple", "banana", "cherry"]})
print(df.loc[1, "fruits"])
Summary
c9-python-getting-started is a beginner-friendly introduction to Python, focusing on basic concepts and syntax. It's ideal for those new to programming or Python specifically.
pandas is a powerful data manipulation library for Python, offering advanced features for data analysis and processing. It's better suited for intermediate to advanced users working with complex datasets.
While c9-python-getting-started provides a gentle entry point to Python programming, pandas offers more sophisticated tools for data-centric applications. The choice between them depends on the user's experience level and project requirements.
scikit-learn: machine learning in Python
Pros of scikit-learn
- Comprehensive machine learning library with a wide range of algorithms and tools
- Well-documented and actively maintained by a large community
- Seamless integration with other scientific Python libraries like NumPy and pandas
Cons of scikit-learn
- Steeper learning curve for beginners in machine learning
- More complex setup and installation process
- Requires more computational resources for large-scale projects
Code Comparison
c9-python-getting-started:
# Basic Python syntax example
name = input("What's your name? ")
print(f"Hello, {name}!")
scikit-learn:
# Simple machine learning example using scikit-learn
from sklearn.datasets import load_iris
from sklearn.model_selection import train_test_split
from sklearn.tree import DecisionTreeClassifier
X, y = load_iris(return_X_y=True)
X_train, X_test, y_train, y_test = train_test_split(X, y, random_state=0)
clf = DecisionTreeClassifier().fit(X_train, y_train)
The c9-python-getting-started repository is designed for beginners learning Python basics, while scikit-learn is a specialized library for machine learning tasks. c9-python-getting-started offers a gentler introduction to programming concepts, making it more suitable for newcomers. In contrast, scikit-learn provides powerful tools for data analysis and predictive modeling, catering to more advanced users and specific machine learning applications.
Convert
designs to code with AI
Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.
Try Visual CopilotREADME
Getting started with Python
Overview
These three series on Channel 9 and YouTube are designed to help get you up to speed on Python. If you're a beginning developer looking to add Python to your quiver of languages or trying to get started on data science or web project which uses Python, these videos are here to help show you the foundations necessary to walk through a tutorial or other quick start.
We do assume you are familiar with another programming language, and some core programming concepts. For example, we highlight the syntax for boolean expressions and creating classes, but we don't dig into what a boolean is or object oriented design. We show you how to perform the tasks you're familiar with in other languages in Python.
What you'll learn
- The basics of Python
- Common syntax
- Popular packages
Prerequisites
- Light experience with another programming language, such as JavaScript, Java or C#
- An understanding of Git
Courses
Getting started
Python for beginners is the perfect starting location for getting started. No Python experience is required! We'll show you how to set up Visual Studio Code as your code editor, and start creating Python code. You'll see how to manage create, structure and run your code, how to manage packages, and even make REST calls.
Dig a little deeper
More Python for beginners digs deeper into Python syntax. You'll explore how to create classes and mixins in Python, how to work with the file system, and introduce async/await
. This is the perfect next step if you're looking to see a bit more of what Python can do.
Peek at data science tools
Even more Python for beginners is a practical exploration of a couple of the most common packages and tools you'll use when working with data and machine learning. While we won't dig into why you choose particular machine learning models (that's another course), you will get hands-on with Jupyter Notebooks, and create and test models using scikit-learn and pandas.
Next steps
As the goal of these courses is to help get you up to speed on Python so you can work through a quick start. The next step after completing the videos is to follow a tutorial! Here are a few of our favorites:
- Quickstart: Detect faces in an image using the Face REST API and Python
- Quickstart: Analyze a local image using the Computer Vision REST API and Python
- Quickstart: Using the Python REST API to call the Text Analytics Cognitive Service
- Tutorial: Build a Flask app with Azure Cognitive Services
- Flask tutorial in Visual Studio Code
- Django tutorial in Visual Studio Code
- Predict flight delays by creating a machine learning model in Python
Contributing
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.
When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.
Top Related Projects
Python extension for Visual Studio Code
The Python micro framework for building web applications.
The Web framework for perfectionists with deadlines.
The fundamental package for scientific computing with Python.
Flexible and powerful data analysis / manipulation library for Python, providing labeled data structures similar to R data.frame objects, statistical functions, and much more
scikit-learn: machine learning in Python
Convert
designs to code with AI
Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.
Try Visual Copilot