Version française
Home     About     Download     Resources     Contact us    
Browse thread
beginners list
[ Home ] [ Index: by date | by threads ]
[ Search: ]

[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: -- (:)
From: Jon Harrop <jon@f...>
Subject: Re: [Caml-list] beginners list
On Saturday 24 February 2007 18:43, christian konrad wrote:
> (Scanf.sscanf line "%d\t%d\t%d\t%d" createErgebnis) ::
> (readErgebnisse fh (number-1)); 

I think you've made exactly the same mistake here. Also, the outer brackets 
are superfluous. You probably want:

  let line = Scanf.sscanf line "%d\t%d\t%d\t%d" createErgebnis in
  line :: readErgebnisse fh (number-1)

but it depends whether you wanted to recurse first or read a line first (I 
can't tell from your code and neither can the compiler).

-- 
Dr Jon D Harrop, Flying Frog Consultancy Ltd.
OCaml for Scientists
http://www.ffconsultancy.com/products/ocaml_for_scientists