CodeSkulptor
""" 
1
""" 
2
Welcome to Codeskulptor's visualization mode (Viz mode)!
3
Viz mode runs in Chrome, Firefox or Safari
4
 
5
Click the wrench button above to active Viz mode, then
6
click the triangle button to visualize the execution of
7
the demo program
8
"""
9
 
10
def list_minimum(numbers):
11
    """
12
    Compute the minimum of a list of numbers
13
    """
14
    
15
    min_num = float("inf")
16
    for num in numbers:
17
        if num < min_num:
18
            min_num = num  # Set breakpoint on this line
19
    return min_num
20
 
21
example_list = [4.6, 5.9, 2.1, 5.7, 1.1, 8.3]
22
print "An example list is", example_list
23
print 
24
minimum_number = list_minimum(example_list)
25
print "The minimum of this example list is", minimum_number
26
 
27
 
28
 
29
# The light blue bars in the code editor and console
30
# indicate the current active line/event. 
31
 
32
# Navigate the execution trace of your program using 
33
# the next/prev statement buttons. 
34
 
35
# Click a line number to set a breakpoint for a line
36
# Navigate between execution trace breakpoints using 
37
# the next/prev breakpoint/event buttons
38
 
 
CodeSkulptor was built by Scott Rixner and is based upon CodeMirror and Skulpt. Viz mode was built by Terry Tang and utilizes Online Python Tutor's visualization code.