Siddhartha spent several years fasting and practicing what?

Siddhartha spent several years fasting and practicing asceticism, which is a severe self-discipline that avoids all type of human indulgences. However, he later rejected this type harsh type of asceticism because it impeded the ultimate path to nirvana. He modified this to a practice that while not descending into the self denial of asceticism, did not cross over into luxury and indulgence either.