cpython/Demo/comparisons
Georg Brandl f004d9dc84 Merged revisions 73206,73232,73299,73683,74020,74185,74544,74643,74647,74817,74838-74839,74865,74946,75402,75459,75604,75696 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/trunk

........
  r73206 | georg.brandl | 2009-06-04 11:15:12 +0200 (Do, 04 Jun 2009) | 1 line

  #3584: ignore trailing newlines when placing the caret for a SyntaxError location.
........
  r73232 | georg.brandl | 2009-06-04 20:59:58 +0200 (Do, 04 Jun 2009) | 1 line

  Add test for #3684.
........
  r73299 | georg.brandl | 2009-06-08 20:41:36 +0200 (Mo, 08 Jun 2009) | 1 line

  Typo fix.
........
  r73683 | georg.brandl | 2009-06-29 16:44:49 +0200 (Mo, 29 Jun 2009) | 1 line

  Fix error handling in PyCode_Optimize, by Alexander Schremmer at EuroPython sprint.
........
  r74020 | georg.brandl | 2009-07-16 09:18:07 +0200 (Do, 16 Jul 2009) | 1 line

  #5910: fix kqueue for calls with more than one event.
........
  r74185 | georg.brandl | 2009-07-23 11:17:09 +0200 (Do, 23 Jul 2009) | 1 line

  Fix the "pylocals" gdb command.
........
  r74544 | georg.brandl | 2009-08-24 19:12:30 +0200 (Mo, 24 Aug 2009) | 1 line

  #6775: fix python.org URLs in README.
........
  r74643 | georg.brandl | 2009-09-04 08:59:20 +0200 (Fr, 04 Sep 2009) | 2 lines

  Issue #2666: Handle BROWSER environment variable properly for unknown browser names in the webbrowser module.
........
  r74647 | georg.brandl | 2009-09-04 10:17:04 +0200 (Fr, 04 Sep 2009) | 2 lines

  Issue #5275: In Cookie's Cookie.load(), properly handle non-string arguments as documented.
........
  r74817 | georg.brandl | 2009-09-16 11:05:11 +0200 (Mi, 16 Sep 2009) | 1 line

  Make deprecation notices as visible as warnings are right now.
........
  r74838 | georg.brandl | 2009-09-16 18:22:12 +0200 (Mi, 16 Sep 2009) | 1 line

  Remove some more boilerplate from the actual tests in test_pdb.
........
  r74839 | georg.brandl | 2009-09-16 18:36:39 +0200 (Mi, 16 Sep 2009) | 1 line

  Make the pdb displayhook compatible with the standard displayhook: do not print Nones. Add a test for that.
........
  r74865 | georg.brandl | 2009-09-17 09:49:37 +0200 (Do, 17 Sep 2009) | 1 line

  #6912: add "with" block support to pindent.
........
  r74946 | georg.brandl | 2009-09-19 10:43:16 +0200 (Sa, 19 Sep 2009) | 1 line

  Update bug tracker reference.
........
  r75402 | georg.brandl | 2009-10-14 17:51:48 +0200 (Mi, 14 Okt 2009) | 1 line

  #7125: fix typo.
........
  r75459 | georg.brandl | 2009-10-17 10:57:43 +0200 (Sa, 17 Okt 2009) | 1 line

  Fix refleaks in _ctypes PyCSimpleType_New, which fixes the refleak seen in test___all__.
........
  r75604 | georg.brandl | 2009-10-22 13:36:50 +0200 (Do, 22 Okt 2009) | 1 line

  Fix stylesheet for multi-paragraph impl-details.
........
  r75696 | georg.brandl | 2009-10-25 21:25:43 +0100 (So, 25 Okt 2009) | 1 line

  Fix a demo.
........
2009-10-27 15:39:53 +00:00
..
README
patterns
regextest.py SF Bug #1348477, regextest can't be pydoc'ed. Will backport. 2005-11-09 07:07:58 +00:00
sortingtest.py Merged revisions 73206,73232,73299,73683,74020,74185,74544,74643,74647,74817,74838-74839,74865,74946,75402,75459,75604,75696 via svnmerge from 2009-10-27 15:39:53 +00:00
systemtest.py Run these demo scripts through reindent.py to give them 4-space indents. I've verified that their output is unchanged. 2003-04-24 17:13:18 +00:00

README

Subject: Re: What language would you use?
From: Tom Christiansen <tchrist@mox.perl.com>
Date: 6 Nov 1994 15:14:51 GMT
Newsgroups: comp.lang.python,comp.lang.tcl,comp.lang.scheme,comp.lang.misc,comp.lang.perl
Message-Id: <39irtb$3t4@csnews.cs.Colorado.EDU>
References: <39b7ha$j9v@zeno.nscf.org> <39hhjp$lgn@csnews.cs.Colorado.EDU> <39hvsu$dus@mathserv.mps.ohio-state.edu>

[...]
If you're really into benchmarks, I'd love it if someone were to code up
the following problems in tcl, python, and scheme (and whatever else you'd
like).  Separate versions (one optimized for speed, one for beauty :-) are
ok.  Post your code so we can time it on our own systems.

0)  Factorial Test  (numerics and function calls)

        (we did this already)

1)  Regular Expressions Test

    Read a file of (extended per egrep) regular expressions (one per line), 
    and apply those to all files whose names are listed on the command line.
    Basically, an 'egrep -f' simulator.  Test it with 20 "vt100" patterns
    against a five /etc/termcap files.  Tests using more elaborate patters
    would also be interesting.  Your code should not break if given hundreds
    of regular expressions or binary files to scan.  

2)  Sorting Test

    Sort an input file that consists of lines like this

        var1=23 other=14 ditto=23 fred=2

    such that each output line is sorted WRT to the number.  Order
    of output lines does not change.  Resolve collisions using the
    variable name.   e.g.

        fred=2 other=14 ditto=23 var1=23 

    Lines may be up to several kilobytes in length and contain
    zillions of variables.

3)  System Test

    Given a list of directories, report any bogus symbolic links contained
    anywhere in those subtrees.  A bogus symbolic link is one that cannot
    be resolved because it points to a nonexistent or otherwise
    unresolvable file.  Do *not* use an external find executable.
    Directories may be very very deep.  Print a warning immediately if the
    system you're running on doesn't support symbolic links.


I'll post perl solutions if people post the others.


--tom
-- 
Tom Christiansen      Perl Consultant, Gamer, Hiker      tchrist@mox.perl.com

 "But Billy! A *small* allowance prepares you for a lifetime of small
 salaries and for your Social Security payments."    --Family Circus