Interactive Python and machine-learning studio

Python AI/ML Coding Studio

Write and run Python-style scripts entirely inside one HTML file. Practice language fundamentals, inspect variables and files, analyze tabular data, train small regression, classification, and clustering models, calculate evaluation metrics, render plots, and complete a documented AI/ML capstone.

Standalone HTMLOffline AI/ML runtimeNo host code executed
Python AI/ML WorkbenchOffline teaching interpreter, project files, variables, metrics, and plots
ready
0 steps
hello.pyCtrl+Enter run · Ctrl+S save · Tab indent
no plot
Run a Python script to see standard output here.
Lesson 01 - Orientation

Write and run Python in a safe browser laboratory

The coding workbench combines an editor, standard-output console, variable inspector, virtual project files, plotting canvas, guided missions, and a purpose-built teaching interpreter. It supports core Python plus compact NumPy-, pandas-, Matplotlib-, and scikit-learn-style APIs for small educational AI/ML experiments.

Run a scriptInspect output and variablesUnderstand the supported subsetSave or export project work
1

What executes here

A deterministic educational runtime designed for small scripts

PY

Python foundations

Variables, expressions, strings, lists, dictionaries, sets, conditionals, loops, comprehensions, functions, and common built-ins.

DATA

Data analysis

Small numerical arrays, DataFrames, Series, CSV data, descriptive statistics, sorting, grouping, and transformation.

ML

Machine learning

Synthetic datasets, train/test splitting, feature scaling, linear and logistic regression, k-nearest neighbors, K-Means, metrics, and charts.

Important simulation boundary

This page does not launch the computer's Python installation, install packages, access the network, or execute arbitrary native code. It interprets a documented teaching subset inside the browser. Use an actual Python environment for production behavior, full language coverage, large datasets, or third-party packages.

2

First run

Use the supplied hello.py project file

01

Read the starting script

The editor contains variables, a list, an f-string, and arithmetic.

# Start here: edit this script and press Run name = "student" print(f"Hello, {name}!") values = [12, 18, 21, 25, 29] print("count:", len(values)) print("mean:", round(sum(values) / len(values), 2))
02

Run with Ctrl+Enter

The Run button and Ctrl+Enter execute the active .py file. Output and errors appear beside the editor.

print("Python workbench ready")
03

Inspect variables

After execution, open the Variables inspector to see names, types, dimensions, and previews.

course = "AI/ML" values = [2, 4, 8, 16] mean_value = sum(values) / len(values) print(course, mean_value)
04

Change and rerun

Edit the name or values, save, and run again. Files and progress persist in this browser.

name = "researcher" print(f"Welcome, {name}")

Knowledge check

Which statement best describes the runtime?