From: Vincent Foley Date: 2002-09-23T23:44:30+09:00 Subject: Re: Speed up suggestions In my experience, Python is faster than Ruby. I made a small script to help me do crossword puzzles. The first thing I do, is open a dictionary file and put it in memory: Ruby: _wordList = open('/home/vince/fr_dict.txt', 'r').read.split('\n') Python: _wordList = (open('/home/vince/fr_dict.txt', 'r').read()).split('\n') Same thing really. Here are the outputs of time: Ruby: ruby/crosswords.rb 1.52s user 0.13s system 68% cpu 2.407 total Python: python/crossword.py 0.52s user 0.07s system 31% cpu 1.875 total Python went over that file much more quickly. Maybe my technique for opening a file in Ruby could be accelerated, but I think that the speed of the Python interpreter is just greater than that of Ruby, that's all. Vince -- Vincent Foley-Bourgon Email: vinfoley@iquebec.com Homepage: http://darkhost.mine.nu:81