CNS 1400 Midterm #2 Study Guide

The objective of this examination is to provide both you and me with some measure of the learning that you have accomplished up to this point in the semester. Learning to program is much more than just being able to regurgitate facts about a particular programming language, and the mechanics of getting a program to compile and execute. This exam will test your understanding of basic programming principles and your ability to apply those principles correctly to solve difficult computing problems. Although this exam will focus on the material most recently covered, you should consider it comprehensive. The exam contains a number of multiple choice questions, some short answer questions, and some questions that require you to write some code.

This exam is OPEN BOOK. You may bring your textbook to class to use as a reference for C# syntax. However, you may not use class notes, copies of slides presented in class, or crib notes of any kind. Foreign students may bring a foreign language-English dictionary to the testing center.

You will be responsible for the material discussed in class as well as the textbook reading assignments and all of the labs and programming assignments.

Topic Study Material
Program Design
    You should be able to
    • Describe the steps in the software development process
    • Describe the steps required to develop an algorithm
    • Break a word problem down into a series of steps that will solve the problem
    • Create an activity diagram
    • Write pseudo-code
    • Explain what it means to desk check your code.
  • Slides on Program Design
  • Chapter 5 in the Course Notes Book
  • Labs 8 and 9
  • Project 3
  • Demonstrate that you know how to use the built-in methods discussed in class, amd how to generate random numbers.
  • Be able to correctly write and use a stand-alone method in C#.
  • Be able to describe the concept of scope and how it effects the execution of a program.
  • Be able to explain the term method prologue and be able to write a proper method prologue.
  • Show that you understand how methods are called and how they return control to main.
  • Slides on Methods

  • Chapter 6 in the Course Notes book

  • Labs 10 and 11

  • Project #4
Object Oriented Design
    You should be able to
    • Explain what a class is
    • Describe the relationship between a class and an object of that class
    • Correctly create a class diagram
    • Write code for a class, given a class diagram
    • Explain the concept of encapsulation
    • Design and code a class for a given programming problem
    • Use a class of your own design in a program
  • Slides on Object Oriented Design
  • Chapters 7 and 8 in the Course Notes Book
  • Labs 12, 13, 14 and 15
  • Project 5
Flow of Control
  • Be able to trace the normal flow of control through a C# program, and then show how that flow is altered by
    • if statements
    • if/else statements
    • switch statements
    • for statements
    • do statements
    • do/while statements
  • Be able to evaluate and use boolean expressions correctly.
  • Be able to use logical operators in complex boolean expressions.
  • Show that you know what an enumeration is and how to use one.
  • Show that you can correctly use while and break.
  • Given a computational problem, show that you can
    • Create an algorithm to solve the problem.
    • Create a UML activity diagram to express the steps in the alogorithm.
    • Use stepwise refinement to solve more complex problems.
    • Translate an algorithm into code.
    • Debug a program using your algorithm.
  • Slides on Flow of Control
  • Chapters 9 and 10 in the Course Notes Book
  • Labs 16, 17, 19, and 20
  • Projects 6 and 7