How to Compile Your First Function

May 30, 2026 | 5 min read

Step 1: Write a Function

def square_sum(n: int) -> int:
    total = 0
    for i in range(n):
        total += i * i
    return total

Step 2: Save to File

# save as math_ops.py

Step 3: Compile

pyvorin compile math_ops.py --function square_sum

Step 4: Check Status

pyvorin job status JOB_ID

Step 5: Run

pyvorin run math_ops.py --function square_sum