NextGWriteHelpers to write simple space-based files like the ones used in the Google Hash Code competition.
val int : int castval bit : bool castval float : float castCast a float using the %g specification (see Printf).
val char : char castval string : string castFor each tuple size n (up to 5), we provide a function tuplen and a function tupleng, the former taking one cast and the latter taking n casts ("g" stands for "generic").
tuple2g c1 c2 is a cast that takes a pair, applies c1 on the first part and c2 on the second part and glues the result with a space character.
val to_string : 'a cast -> 'a -> stringto_string c v casts v using c and returns the result as a string.
val line : 'a cast -> 'a -> unitline c v casts v using c and writes the result to standard output, adding a newline character.
val line_to_err : 'a cast -> 'a -> unitline_to_err c v casts v using c and writes the result to standard error, adding a newline character.
val line_to_chan : Stdlib.out_channel -> 'a cast -> 'a -> unitline_to_chan ochan c v casts v using c and writes the result to ochan, adding a newline character.