Introduction to Computer Science with GenAI
Course description
This course introduces students to foundational concepts of computer science. The curriculum provides instruction through guided inquiry activities and related slide decks, practice through lab and homework tasks, and assessment through unit quizzes and unit projects. The unit projects require students to synthesize various skills while developing larger programs. Students will use a GenAI tool during the course, but any GenAI tool is acceptable.
Pre-requisites: This course has no prerequisites, so prior programming experience is not needed.
Course Language: Python
What students will learn
- Foundational programming concepts, including using conditional and iterative logic, defining and calling functions, performing operations on strings, lists, and dictionaries, and working with files.
- Programming skills, such as debugging code, testing code, and decomposing problems into functions.
- Best practices for using GenAI, including developing effective prompts, evaluating GenAI output, and identifying ways to leverage AI during the programming process.
Units
The total course is designed for a 15-week semester. Materials may be adapted to other schedules.
Unit 1: Foundational concepts
Unit 1 introduces foundational concepts used when developing Python programs. Students focus on variables, data types, input and output, operators, conditional statements, and iterative statements. At the same time, they explore how to best prompt an LLM and evaluate its output so that they can effectively leverage GenAI in a programming context.
- Unit 1 Module 1: Introduction to computer science and GenAI
- Unit 1 Module 2: Data types, variables, and arithmetic operators
- Unit 1 Module 3: Conditional logic
- Unit 1 Module 4: Iterative logic
Unit 2: Functions and methods
Unit 2 introduces functions and methods. Students learn how to define functions and how to decompose larger problems into functions. They explore methods in the context of string and list methods and also examine other techniques for working with strings and lists. Finally, they focus on how they can import modules to incorporate predefined functions and methods into their programs. Within this unit, students also explore how to prompt an LLM to create code for a function, to evaluate and test that code, and to use GenAI to suggest ways to solve a problem.
- Unit 2 Module 1: Functions and problem decomposition
- Unit 2 Module 2: String methods and operations
- Unit 2 Module 3: List methods and operations
- Unit 2 Module 4: Importing modules
Unit 3: Dictionaries and API data exchange
Unit 3 explores the dictionary data type as well as data exchange through APIs. Students first learn how to work with dictionaries through methods and other operations and later focus on working with nested dictionaries and lists. Making API requests is the other primary focus of this unit. Students also continue their exploration of how to leverage GenAI by exploring how LLMs can provide examples of programming concepts in use.
- Unit 3 Module 1: Dictionary methods and operations
- Unit 3 Module 2: API data exchange
- Unit 3 Module 3: Nested dictionaries and lists
Unit 4: Files and data analysis
Unit 4 focuses on working with files and analyzing data. Students learn methods for working with plain text files (.txt and .csv formats) and image files. They also focus on techniques for analyzing the data found in comma-separated value files. Students continue to leverage GenAI as a programming tool.
- Unit 4 Module 1: Plain text files
- Unit 4 Module 2: Data analysis
- Unit 4 Module 3: Image files
- Unit 4 Module 4: Course wrap-up
Related resources
Navigate the course: Introduction to Computer Science with GenAI
Overview of course assets and guide to GenAI use
Introduction to Computer Science with GenAI - Navigate the course: A guide to assets and GenAI use.