python - Importing the `this` module? -
typing following in a python shell not produce error:
from import *
what this
module?
this
zen of python
written tim peters
>>> import * zen of python, tim peters beautiful better ugly. explicit better implicit. simple better complex. complex better complicated. flat better nested. sparse better dense. readability counts. ..... >>> d {'a': 'n', 'c': 'p', 'b': 'o', 'e': 'r', 'd': 'q', 'g': 't', 'f': 's', 'i': 'v', 'h': 'u', 'k': 'x', 'j': 'w', 'm': 'z', 'l': 'y', 'o': 'b', 'n': 'a', 'q': 'd', 'p': 'c', 's': 'f', 'r': 'e', 'u': 'h', 't': 'g', 'w': 'j', 'v': 'i', 'y': 'l', 'x': 'k', 'z': 'm', 'a': 'n', 'c': 'p', 'b': 'o', 'e': 'r', 'd': 'q', 'g': 't', 'f': 's', 'i': 'v', 'h': 'u', 'k': 'x', 'j': 'w', 'm': 'z', 'l': 'y', 'o': 'b', 'n': 'a', 'q': 'd', 'p': 'c', 's': 'f', 'r': 'e', 'u': 'h', 't': 'g', 'w': 'j', 'v': 'i', 'y': 'l', 'x': 'k', 'z': 'm'} >>> c '!'
and why from import *
raise error?
using above syntax merges this
module's namespace current namespace.
>>> import >>> dir(this) ['__builtins__', '__doc__', '__file__', '__name__', '__package__', 'c', 'd', 'i', 's']
also try:
import antigravity
Comments
Post a Comment