This subject is aimed at students with little or no programming experience. It aims to provide students with an understanding of the role computation can play in solving problems. It also aims to help students, regardless of their major, to feel justifiably confident of their ability to write small programs that allow them to accomplish useful goals. The class will use the Python programming language.
Goals of the course; what is computation; introduction to data types, operators, and variables
Operators and operands; statements; branching, conditionals, and iteration
Decomposition and abstraction through functions; introduction to recursion
Floating point numbers, successive refinement, finding roots
Lists and mutability, dictionaries, pseudocode, introduction to efficiency
More about debugging, knapsack problem, introduction to dynamic programming
Dynamic programming: overlapping subproblems, optimal substructure
Analysis of knapsack problem, introduction to object-oriented programming
Course overview; what do computer scientists do?
Validating simulation results, curve fitting, linear regression
Normal, uniform, and exponential distributions; misuse of statistics