intro to ML
Henry Cejtin
henry@sourcelight.com
Wed, 24 Oct 2001 20:16:38 -0500
I was trying to decide if I should just stick to the core language. I gather
you think that that is wrong? I guess either way you have to say something
about the module language so that they can get to the standard basis. The
problem is that then they really have to be able to produce types instead of
just observing them.
Unfortunately I see I really am not going to have enough time to get very
far. The whole notion of polymorphic types, since they have never seen any
thing like that, is probably a session in and of itself, as is the idea of
using types to drive things, as is the whole aspect of variables not varying.
Still, I have hooks to get them interested. I had to write some simple hack
reading through a largish text file (30 meg) and extracting fields
(`|'-separated). I used the Substring structure a lot. The result was most
excellent. Very clean, very simple and very fast. I wrote versions in
Python and using awk (awk has VERY fast I/O but isn't a real full language).
The result was that the sizes were all about the same (MLton less than 5%
bigger than awk with Python being 35% bigger) but the speeds were:
MLton 5.3 CPU seconds
awk 15.3 CPU seconds
Python 277.8 CPU seconds