Code Execution Skill
This skill allows running Python code in a sandboxed embedded environment.
Capabilities
- •Pure Python Logic: Run algorithms, mathematical calculations, and string processing.
- •Sandboxed: No access to file system or network.
- •State: Execution is stateless (variables do not persist between calls).
Limitations
- •No standard library I/O (
os,sys,io,socketare not available). - •No external packages (
numpy,pandas,requestsare not available). - •Only
print()values are captured. Print any values you want to view.
Guidelines
- •Prefer iteration over recursion
- •Prefer efficiency over readability
Examples
Calculate Fibonacci
python
def fib(n):
a, b = 0, 1
for i in range(0, n):
a, b = b, a + b
return a
print(fib(10))
Text Processing
python
text = "hello world" print(text.upper()[::-1])