Code is not created all at once. He would have been determining the best rules to use by testing them. He likely had a computer crunching away for months to prove the difficulty that he later decided was best. His computer would have kept the lowest hash, and that was the best one to use for the genesis block.