From kde-devel Wed Apr 21 18:18:45 2004 From: =?iso-8859-1?q?Lu=EDs_Pedro_Coelho?= Date: Wed, 21 Apr 2004 18:18:45 +0000 To: kde-devel Subject: Re: Two optimization questions Message-Id: <200404211918.50117.luis () luispedro ! org> X-MARC-Message: https://marc.info/?l=kde-devel&m=108257159603627 -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 Maybe this is pointing out the obvious, but then again, maybe not: On Tuesday 20 April 2004 22:23, Adriaan de Groot wrote: >         QStringList::constIterator e = l.end(); >         for (QStringList::constIterator i = l.begin() ; i!=e; ++i) { .. } I tend to use this, but you can write it all in one line (with the correct variable scope, as well): for (QStringList::constIterator i = l.begin(), e =l.end(); i != e; ++i) { ... } Regards, - -- Luís Pedro Coelho check out my game of hearts for the KDE at http://hearts.luispedro.org -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (GNU/Linux) iD8DBQFAhrsIGpBAvyRwXdgRAo53AJ41cPPInFobtb0wBQh9at85mXejegCfTMAr 3XgRvf6dSkOSqGlz+GJAMvU= =QTRy -----END PGP SIGNATURE----- >> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<