The purpose of this study was to investigate and compare the effect of the two computer-assisted learning systems named the Example-Based Dynamic Program Visualization Environment (EDPVE) and the Example-Based Static Program Visualization Environment (ESPVE) on undergraduate students' programming skills in an introductory programming course. The study was conducted using a quasi-experimental, non-equivalent control group design with 81 pre-service teachers in a Turkish university. Two classes were randomly assigned to use EDPVE(experimental group) and ESPVE(control group) system. The results of the experiments showed that: (1) there were a significant difference between EDPVE and ESPVE groups in favour of the EDPVE group; and (2) there were no significant difference between male and female students in EDPVE and ESPVE groups respectively. The findings of this study suggest that teaching and learning programming can be improved through the use of dynamic program visualization techniques.