<br><div>Code Blit:</div><div><br></div><div>The string module has translate and maketrans, through multiple versions. In per 3.x, </div><div>an optional argument listed "letters to delete". </div><div><br></div>
<div>The first argument was a kind of mapping, of 256 symbols to itself, except with some </div><div>letters changed, what we would call a "permutation" in group theory (not promising </div><div>a bijectional one-to-one mapping, no way, more likely surjective, do we agree?).</div>
<div><br></div><div><a href="http://www.youtube.com/watch?v=xKNX8BUWR0g">http://www.youtube.com/watch?v=xKNX8BUWR0g</a></div><div><br></div><div>Here we are in 2.6, where the bytes type is not yet operative.</div><div><br>
</div><div><div>IDLE 2.6.5 </div><div>>>> b'a'</div><div>'a'</div><div>>>> type(b'a')</div><div><type 'str'></div></div><div><br></div><div>Now let's replay that action in 3.1:</div>
<div><br></div><div><div>>>> b'a'</div><div>b'a'</div><div>>>> type(b'a')</div><div><class 'bytes'></div></div><div><br></div><div>Here's my idea of a punctuation filter in 3.x, where the delete characters clause</div>
<div>is now a delete bytes clause in the byte type superobject.</div><div><br></div><div><div>import string</div><div>def filterpunc(thestr):</div><div> return thestr.encode('utf-8').translate(bytes.maketrans(b'',b''), string.punctuation.encode('utf-8')).decode('utf-8')</div>
<div><br></div><div>See:</div><div><a href="http://diveintopython3.org/strings.html">http://diveintopython3.org/strings.html</a></div><div><a href="http://www.devx.com/opensource/Article/42659/1763">http://www.devx.com/opensource/Article/42659/1763</a></div>
<div>if curious.</div></div><div><br></div><div>This'd be used to strip string.punctuation characters out of any string. Other solutions possible, including with regexps.</div><div><br></div><div>Suggestions for Features (SFFs -- not as prestigious or important as PEPs </div>
<div>but sometimes the genetic precursor of a PEP).</div><div><br></div><div>Save Session in IDLE or other PyShell:</div><div><br></div><div>This is probably already out there, in IPython or one of those. It's</div><div>
so cool to be able to interactively bind names to working code in </div><div>memory, but when you resume your session later, all that has </div><div>gone away. In some other shell environments, you have the </div><div>option to hibernate and resume, Smalltalk's being the most famous.</div>
<div><br></div><div>Would it come with a source code snapshot version that encapsulates </div><div>all the definitions as runnable code? The latest version of f, all </div><div>the latest object values? That's another way to "pickle", to just </div>
<div>write out a module that recreates what was there, when run.</div><div><br></div><div>Python in Mathland:</div><div><br></div><div>A link to a recent summary that mentions Python quite a bit:</div><div><a href="http://groups.google.com/group/mathfuture/browse_thread/thread/3d642708c2f2a80?hl=en">http://groups.google.com/group/mathfuture/browse_thread/thread/3d642708c2f2a80?hl=en</a></div>
<div><br></div><div>Kirby</div><div><br></div>