Evolution is based on random mutations and does not guarantee perfect traits.

The beak sizes of Galapagos finches of a given species can vary within a few short years:

Traits are not perfect, but are results of adaptation.