Why are ancient poems in a row of five or seven words?

Five words and one sentence are called five-word ancient poems, which are referred to as five ancient poems for short; Seven words and one sentence are called seven-word ancient poems, which are referred to as seven ancient poems for short. Ancient poetry is represented by five words and seven languages. Five-character ancient poetry is the orthodoxy of ancient poetry, and many people write it. Seven-character ancient poetry is not the mainstream of ancient poetry, because it originated late. Therefore, the seven-character style is greatly influenced by the seven-character modern poetry. Five-character ancient poems and seven-character ancient poems are both ancient poems with neat words.