Novice computer programmers need to acquire a diverse set of skills to become proficient in the various areas of program development. This work investigates some of the cognitive processing demands of computer programming, and investigates the factors affecting success in learning the required skills. In the empirical research described, achievement on an introductory programming course was tested for possible correlation with individual learner characteristics, including learning style and background knowledge. The subjects of the research belonged to five different teaching groups, enabling the additional factors of learning environment and teaching method to be considered. Significant differences were observed in areas of programming skill acquisition between subjects of different learning styles. The way that knowledge, attitudes, aptitude, personality traits and learning styles interact, and the implications of the results for designing individualised learning strategies and predicting success in learning to program, are discussed.