Hello Arnaud, > I have started a small project whose purpose is to simulate Darwin's > theory and I would really appreciate some code review from more > experienced scheme developers, esp. when it comes to structuring, > idiomatic code patterns, egg definitions...
I'd generally recommend studying Riastradh's style guide [1]_. That aside: - Stick closing parentheses together. - No need to use begin in let and let*, it's doing an implicit begin. - Why bind variables with let, then immediately set! them? For side-effectful values I'd just use let* with the corresponding expression. - print takes several arguments, so no need to string-append them. - Consider doing some basic encapsulation by writing constructor/accessor procedures, that makes swapping out the implementation a lot easier. SICP has a bunch of things to say on the topic. [1]: https://mumble.net/~campbell/scheme/style.txt
signature.asc
Description: PGP signature