Domanda

import system module does not work in python2.7.3 

Python 2.7.3 (default, Mar 13 2014, 11:03:55)

[GCC 4.7.2] on linux2
Type "help", "copyright", "credits" or "license" for more information.

 >>> import system
 Traceback (most recent call last):
      File "<stdin>", line 1, in <module>
    ImportError: No module named system
È stato utile?

Soluzione

If you wish for the sys module, try:

import sys

If you're looking for the system call, try:

import os.system
Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top