On Tue, 2002-05-28 at 14:25, Steve Juranich wrote:
> Here's a chunk of Python code that should do the trick.
>
> lines = open(filename).readlines()
>
> line_dict = {}
> for line in lines:
> if line not in line_dict.keys():
> print line
> line_dict[line] = 1
>
> I haven't debugged/tested this. YMMV.
That'll work, but imagine the performance when there are, say,
75,000 lines, each 50 bytes...
--
+---------------------------------------------------------+
| Ron Johnson, Jr. Home: [EMAIL PROTECTED] |
| Jefferson, LA USA http://ronandheather.dhs.org:81 |
| |
| "I have created a government of whirled peas..." |
| Maharishi Mahesh Yogi, 12-May-2002, |
! CNN, Larry King Live |
+---------------------------------------------------------+
--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]