Computation is required for biologists given the prevalence of analysis of large datasets, complex models, and data visualization. Though computation is becoming an essential skill for biologists, students often perceive the practice as too difficult for them. We created an activity that uses computational modeling of polygenic inheritance to teach students both computation and genetics. Our activity introduces students to basic programming using an organizational scheme that enables students to make sense of code by relying on their knowledge of genetics. Additionally, our activity explores polygenic inheritance with the development of skin color to help explain why race is not a biological concept. We extend this activity to microbiology with an interactive discussion and simple example of creating a microbe model. Though our skin color modeling activity focuses on genetics as a learning outcome, the organizational scheme provides a basis for activities in various biology and microbiology courses.