Ah, so you are trying to translate Wei Zheng’s analects.
The full quote is:
“吾十有五而志于学,三十而立,四十而不惑,五十而知天命,六十而耳顺,七十而从心所欲,不逾矩。”
An approximative translation would be:
“At fifteen, I was focused on learning. At thirty, I stood firm. At forty, I had no doubts. At fifty, I knew the decrees of heaven. At sixty, my ear was tuned to truth. At seventy, I could follow my heart’s desires, without transgressions .”