- 论坛徽章:
- 0
|
试了一下,好像没问题。不知道是不是RC2作了修补。
- Python 3.0rc2 (r30rc2:67114, Nov 7 2008, 13:18:49)
- [GCC 3.4.6 20060404 (Red Hat 3.4.6-9)] on linux2
- Type "help", "copyright", "credits" or "license" for more information.
- >>> print ('hello')
- hello
- >>> import subprocess
- >>> dir(subprocess)
- ['CalledProcessError', 'MAXFD', 'PIPE', 'Popen', 'STDOUT', '__all__', '__builtins__', '__doc__', '__file__', '__name__', '__package__', '_active', '_cleanup', '_demo_posix', '_demo_windows', 'call', 'check_call', 'errno', 'fcntl', 'gc', 'getoutput', 'getstatusoutput', 'io', 'list2cmdline', 'mswindows', 'os', 'pickle', 'select', 'signal', 'sys', 'traceback']
- >>> subprocess.getoutput('dir')
- '2to3 idle pydoc python3.0 python3.0-config\tsmtpd.py'
复制代码 |
|