the very first draft
fixes few bugs in fitness computation