Received: from spf3.us4.outblaze.com (spf3.us4.outblaze.com [205.158.62.25]) by sdf.lonestar.org (8.12.10/8.12.10) with ESMTP id iACGBNP0002250 for ; Fri, 12 Nov 2004 16:11:24 GMT Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) by spf3.us4.outblaze.com (Postfix) with ESMTP id 20E7854946 for ; Fri, 12 Nov 2004 16:09:53 +0000 (GMT) Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CSe8H-000480-1C for migo@homemail.com; Fri, 12 Nov 2004 11:18:41 -0500 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.33) id 1CSe7p-00046l-NM for gnu-arch-users@gnu.org; Fri, 12 Nov 2004 11:18:13 -0500 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.33) id 1CSe7o-00046G-OH for gnu-arch-users@gnu.org; Fri, 12 Nov 2004 11:18:12 -0500 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.33) id 1CSe7o-000466-LE for gnu-arch-users@gnu.org; Fri, 12 Nov 2004 11:18:12 -0500 Received: from [83.216.134.182] (helo=cyclone.suffields.me.uk) by monty-python.gnu.org with esmtp (Exim 4.34) id 1CSdz4-0000kW-AR for gnu-arch-users@gnu.org; Fri, 12 Nov 2004 11:09:10 -0500 Received: from asuffield by cyclone.suffields.me.uk with local (Exim 3.36 #1 (Debian)) id 1CSdz2-0004vF-00 for ; Fri, 12 Nov 2004 16:09:08 +0000 Date: Fri, 12 Nov 2004 16:09:08 +0000 From: Andrew Suffield To: gnu-arch-users@gnu.org Subject: Re: [Gnu-arch-users] Re: darcs vs tla Message-ID: <20041112160908.GA18732@suffields.me.uk> Mail-Followup-To: gnu-arch-users@gnu.org References: <1099995711.2900.84.camel@stargate> <20041110204049.GD5978@suffields.me.uk> <20041111093245.GY721@vagabond> <20041111100931.GB11392@hezmatt.org> <6E1DC26B-340C-11D9-9D7F-000393CFE6B8@spy.net> <20041111222531.GD23560@hezmatt.org> Mime-Version: 1.0 In-Reply-To: User-Agent: Mutt/1.5.6+20040907i X-BeenThere: gnu-arch-users@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: a discussion list for all things arch-ish List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============0366970239==" Sender: gnu-arch-users-bounces+migo=homemail.com@gnu.org Errors-To: gnu-arch-users-bounces+migo=homemail.com@gnu.org Status: RO Content-Length: 2084 Lines: 70 --===============0366970239== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="BOKacYhQ+x31HxR3" Content-Disposition: inline --BOKacYhQ+x31HxR3 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Nov 12, 2004 at 10:37:02AM +0000, Catalin Marinas wrote: > Dustin Sallings writes: > > IN some cases, yeah, quite a bit. For example, how many lines > > of the equivalent of this (contrived because I'm too lazy to look for > > anything better) example in C? > > > > # Create a hash table mapping all of the md5s of the word list > > to the words in the list > > ht =3D dict([ (md5.md5(word).hexdigest(), word) for word in > > words]) >=20 > I wouldn't compare Python with C (maybe assembler with C is a better > comparison) but Python with C++. C++ does not support list > comprehension but you can probably write the above in a single line > (exept for the variable declarations) using the STL library: >=20 > for_each(words.begin(), words.end(), add_to_dict(dict)); That's valid C code. You just need a library... --=20 .''`. ** Debian GNU/Linux ** | Andrew Suffield : :' : http://www.debian.org/ | `. `' | `- -><- | --BOKacYhQ+x31HxR3 Content-Type: application/pgp-signature; name="signature.asc" Content-Description: Digital signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.5 (GNU/Linux) iD8DBQFBlOAklpK98RSteX8RAhLtAJ9/PgvqHPwldO4lP0Yb+pUtXBmSugCfYsQu gjv6YCquOweclUO6X0Y8Ajg= =aq5U -----END PGP SIGNATURE----- --BOKacYhQ+x31HxR3-- --===============0366970239== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Gnu-arch-users mailing list Gnu-arch-users@gnu.org http://lists.gnu.org/mailman/listinfo/gnu-arch-users GNU arch home page: http://savannah.gnu.org/projects/gnu-arch/ --===============0366970239==--