This is more of a 'toy question' than a real one, but can you compile a single line of Python code from the command line using the py_compile module?
My first attempt was python -m py_compile "print 'Hello, Compile!'" but that resulted in an IOError because my_compile thought that I was trying to compile a file named "print 'Hello, Compile!'".
Any ideas?
Note: python -c "CODE" runs the code, it does not produce a *.pyc file with the bytecode.
