Randomly change the prompt in the Python interpreter
According to the docs, if you assign a non-string object to sys.ps1 then it will evaluate the str function of it each time: If a non-string object is assigned to either variable, its str() is re-evaluated each time the interpreter prepares to read a new interactive command; this can be used to implement a dynamic … Read more