SyntaxFix
Write A Post
Hire A Developer
Questions
import os def execute(cmd, callback): for line in iter(os.popen(cmd).readline, ''): callback(line[:-1]) execute('ls -a', print)