examples/module-loading/01_demo.cat
# Demo script using loaded host module with NAMESPACE
# Run with: catnip -f ./examples/host_module_example.py:host examples/demo.cat
# Use host module functions via namespace (host.function())
x = host.add(10, 5)
y = host.multiply(x, 2)
z = host.power(2, 8)
# Call greet function
message = host.greet("Catnip")
# Use Counter class
counter = host.Counter(100)
# Final result
z