Browse thread
[Caml-list] Efficiency of 'a list
-
Eray Ozkural
- Mattias Waldau
- Lauri Alanko
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Mattias Waldau <mattias.waldau@a...> |
| Subject: | RE: [Caml-list] Efficiency of 'a list |
*** Do not use lists, there is always a better datastructure *** > From: Vitaly Lugovsky [mailto:vsl@ontil.ihep.su] > OCaml already have Hashtbl implementation. I know Ocaml has hash tables. Ocaml has ALL the datastructures that are needed to create efficient programs. However, lists are the data structure that it easiest to use, since there is special syntax for it, and therefor many novices use it. The result of this is that you get all these questions in this forum complaining about performance. Most of the questions would never have been asked if the author would have used the correct datastructure, mostly Hash/Map or Set. The reason novices use them is that they think that since there is special syntax for lists, this must be the preferred way. We all know that it isn't the preferred solution. I have been doing pure programming since MACLISP on the TOPS-20, and the a large percentage of performance problems can be traced back to IMAPPROPRIATE USE OF LISTS. Therefor my previous post where I essentially say: *** Do not use lists, there is always a better datastructure *** ------------------- To unsubscribe, mail caml-list-request@inria.fr Archives: http://caml.inria.fr Bug reports: http://caml.inria.fr/bin/caml-bugs FAQ: http://caml.inria.fr/FAQ/ Beginner's list: http://groups.yahoo.com/group/ocaml_beginners