json module Built-in Dry Run in PYTHON

json module Built-in is an interactive PYTHON dry run visualizer from the Builtin programs section. Study the source code, then use the execution controls to follow each step, variable update, highlighted line, and console output.

This page provides a browser-based dry run with source-code highlighting, auto-scroll, voice narration controls, and execution output for learning the program step by step.

json module Built-in Program Code

import json

# Python dictionary
person = {
    "name": "Alice",
    "age": 25,
    "city": "New York",
    "hobbies": ["reading", "coding"]
}

# Convert Python object to JSON string
json_string = json.dumps(person, indent=2)
print("JSON string:")
print(json_string)

# Convert JSON string back to Python object
python_obj = json.loads(json_string)
print("\nName:", python_obj["name"])
print("First hobby:", python_obj["hobbies"][0])

print("Age:", python_obj["age"])

View the complete Builtin programs page.

Program Console json module Built-in Topic: PYTHON Vignaankosh.com
Execution Panel
Step 0/0
Console is empty.