Before enlightenment, Buddha spent 6 long years practicing asceticism and long fasting, causing his body to be weak. One day, he heard someone playing a string instrument and came to the realisation that the Middle Path is the way for achieving the liberation of body and mind.
Cultivation is like playing a musical string instrument. The string will snap if it is too tight, or not make any sound if it is too loose. Indulgence in sensual pleasure or extreme penance are attachments. The Middle Path is the way for achieving the liberation of body and mind.