Just a small Haskell comment:

> +          add_numbers strs = if use_stats 
> +                             then [printf "%3d. %s" n s | (n, s) <- zip nums 
> strs]
> +                             else strs
> +          nums = iterate (+1) (1::Integer)

Perhaps a more concise way to express this might be

 then zipWith (printf "%3d. %s") [1..] strs

So using zipWith as a way to avoid both zipping and doing something over
a list of tuples, and using partial application of printf, and the ..
notation for lists

-- 
Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow>
PGP Key ID: 08AC04F9

Attachment: pgpBwXsUnzCQz.pgp
Description: PGP signature

_______________________________________________
darcs-users mailing list
darcs-users@darcs.net
http://lists.osuosl.org/mailman/listinfo/darcs-users

Reply via email to