Python commands

#!/bin/python # coding=utf-8 import commands def main(): process_listing = commands.getoutput('ls /proc').split('\n') print(process_listing) if __name__ == '__main__': main()
Ejemplo de uso de commands

Be the first to comment

You can use [html][/html], [css][/css], [php][/php] and more to embed the code. Urls are automatically hyperlinked. Line breaks and paragraphs are automatically generated.