I keep telling people "programming is understanding" - the computer is a machine that tests if your ideas are correct. Once you understand a problem the program can usually be written pretty quickly. Understanding a problem can take years.