Introductory computer science courses help students, regardless of their majors, keep up with the rapid pace of change in the workplace. However, such courses are commonly perceived as being difficult. Although many studies have discussed the importance of online introductory computer science courses, there is a dearth of studies investigating the effectiveness of this delivery mode when the same assessment tools are used as in the traditional delivery mode. Moreover, it is unclear how students of different genders perform in both online and traditional face-to-face introductory computer science course sections when they receive the same instructional content. The purpose of this study is to expand the existing literature by examining the academic achievement of students in an introductory computer science course through the evaluation of grades obtained from online and traditional face-to-face course sections. Additionally, the study aims to explore any gender-based variations between the two delivery modes. The sample size included 589 first-year students in an introductory computer science course at a public university in Saudi Arabia. The participants were selected randomly from different sections. The results confirm the findings of previous studies suggesting that there are no gender-based differences in students’ performance in introductory computer science. Additionally, this study makes a valuable contribution to the existing body of literature by demonstrating that students who receive introductory computer science instruction through online delivery mode achieve significantly higher performance than students who receive the same instruction through traditional face-to-dace delivery mode. Moreover, this study found that both female and male students who receive introductory computer science instruction through online delivery mode perform significantly better than male students who receive instruction through traditional face-to-face delivery mode, indicating that online learning may be a more effective mode of delivery for students of both genders.