Docsity

Review for Final Exam - Programming I | EECS 168, Study notes of Electrical and Electronics Engineering

Toggle sidebar
bg1
1
EECS 168 - Fall 2008
Review for Final Exam
Administrative
• When: December 18, Thursday, 7:30-10:00am.
• Where: Professor Kong-1131 Learned.
Professor Brown-120 Snow.
Warning:
Any unauthorized absence from the final exam will result in a zero grade for this
exam.
Read carefully all of the following items....
• Bring your KUID. You will not be allowed to take the exam without your KUID.
• The exam will be closed book, closed notes, and will be held in our regular
classroom.
• No calculators, cell phones, head phones, or electronic devices of any sort will be
allowed. No such devices should be out in the open.
• Once you start the exam, you will not be excused from the room for any reason
unless you turn in your exam. Once it is turned in, you cannot come back and
continue working on it.
Exam Coverage
This is a comprehensive final examination and you are responsible for all material
covered in this course.
Text and subject matter coverage:
• Chapters 1-10, 13-14 of Savitch.
• Material covered in lectures notes and lab/programming assignments.
Topic Review
• Chapter 1: Introduction
o Know the basic concepts of computer and information processing.
o Know the software and hardware components, and their functions, of a
computer system.
o Understand algorithmic problem solving using computer.
o Understand languages and translation, compilation and execution of programs.
o Understand software life cycle.
o Understand basic C++ program structure and different types of program
errors.
o Understand the general approach in testing and debugging a program.
• Chapter 2: Basic C++ Constructs
pf3
pf4
pf5

Partial preview of the text

Download Review for Final Exam - Programming I | EECS 168 and more Study notes Electrical and Electronics Engineering in PDF only on Docsity!

EECS 168 - Fall 2008

Review for Final Exam

Administrative

  • When: December 18, Thursday, 7:30-10:00am.
  • Where: Professor Kong-1131 Learned. Professor Brown-120 Snow.

Warning:

Any unauthorized absence from the final exam will result in a zero grade for this exam.

Read carefully all of the following items....

  • Bring your KUID. You will not be allowed to take the exam without your KUID.
  • The exam will be closed book, closed notes, and will be held in our regular classroom.
  • No calculators, cell phones, head phones, or electronic devices of any sort will be allowed. No such devices should be out in the open.
  • Once you start the exam, you will not be excused from the room for any reason unless you turn in your exam. Once it is turned in, you cannot come back and continue working on it.

Exam Coverage

This is a comprehensive final examination and you are responsible for all material covered in this course.

Text and subject matter coverage:

  • Chapters 1-10, 13-14 of Savitch.
  • Material covered in lectures notes and lab/programming assignments.

Topic Review

  • Chapter 1: Introduction o Know the basic concepts of computer and information processing. o Know the software and hardware components, and their functions, of a computer system. o Understand algorithmic problem solving using computer. o Understand languages and translation, compilation and execution of programs. o Understand software life cycle. o Understand basic C++ program structure and different types of program errors. o Understand the general approach in testing and debugging a program.
  • Chapter 2: Basic C++ Constructs

o Variables and constant identifiers. o Declaration, initialization, and assignment statements. o Executable and non-executable statements. o Simple interactive I/O using cin and cout. o Include and using directives. o Data types, type compatibilities and type casting, and expressions. o Arithmetic, relational, and logical operators; operator hierarchy and evaluation of expressions. o Understand flow of control and the basic concepts of selection and looping. o Simple branching using if-else statements. o Repetition using while- and do-while- loops. o Be able to identify and correct errors in programs. o Be able to execute and generate correct output for programs. o Be able to design and implement C++ programs for various applications.

  • Chapter 3: Flow of Control o Boolean expressions and their applications in branching. o Selection using if-else, nested if-else, and switch statements. o While-, do-while-, and for- loops for repetition. o Nested loop structures. o Designing and debugging loop structures. o Be able to design, implement, and execute codes containing if-else, nested if- else, switch, while-loop, do-while loop, for loop, and nested loop structures.
  • Chapter 4: Procedural Abstraction and Functions o Understand and be able to use top-down design with module programming in program development. o Understand and be able to use step-wise refining in modules development. o Understand and be able to use predefined Functions in C++. o Understand and be able to implement function declaration (prototype) and function definition of programmer-defined functions in C++. o Understand the difference between formal and actual parameters, calling and called functions. o Understand and be able to determine and use the scope of a variable and its containing block. o Understand and be able to define and use local and global variables. o Understand and be able to pass parameters using call-by-value. o Understand and be able to use function overloading. o Understand and be able to use procedural abstraction and information hiding. o Understand and be able to design, implement, and execute functions.
  • Chapter 5: Function and Parameter Passing o Understand and be able to implement void and value-returning functions. o Understand and be able to use call-by-value and call-by-reference in parameter passing. o Understand and be able to define and use pre- and post- conditions of functions. o Be able to design, implement, test and debug functions.

o Understand and be able to access a private member variable of a class. o Understand and be able to call a member function of a class. o Understand and be able to use constructors and default constructors. o Understand and be able to use function overloading in a class structure. o Understand and be able to develop and execute program using structs and classes.

  • Chapter 7: Arrays o Understand and be able to explain and justify the advantages and disadvantages in using arrays. o Understand and be able to declare, initialize, accessing and referencing an array, including multi-dimensional arrays. o Understand and be able to manipulate array using different loop structures. o Understand and be able to use arrays, including const arrays, in functions. o Understand and be able to implement/execute program using arrays and multi- dimensional arrays. o Understand the basic characteristics of various searching and sorting algorithms and be able to implement/execute them.
  • Chapter 8: String & Vector o Understand the differences and similarities among array, strings, and cstrings objects in C++. o Understand and be able to declare, initialize, accessing and manipulating cstrings and strings in C++. o Understand and be able to use standard cstring and string functions. o Understand and be able to do I/O with cstring and string objects. o Understand and be able to use cstrings and strings in functions. o Understand and be able to declare, initialize, accessing and manipulating vectors in C++. o Understand the differences and similarities between array and vector objects.
  • Chapters 9: Pointers & Dynamic Arrays o Understand and be able to access data objects using symbolic name and memory location. o Understand and be able to declare, initialize and use pointers. o Understand and be able to use the “address of” and “dereferencing” operators. o Understand and be able to explain and illustrate, using examples, the difference between static and dynamic variables. o Understand and be able to allocate and de-allocate dynamic variables. o Understand and be able to identify and avoid the problems of dangling pointers and memory leaks. o Understand and be able to use pointers in functions. o Understand and be able to use typedef to define your own data types. o Understand and be able to allocate and de-allocate dynamic arrays. o Understand the differences among pointers, arrays, and dynamic arrays. o Understand and be able to use dynamic variables and dynamic arrays in applications.
  • Chapter 13: Linked Structures o Understand the basic characteristics of linked list data structure.

o Understand the basic structure of a node type and its relation to a linked list structure. o Understand and be able to implement linked list structure using pointer implementation. o Understand and be able to use the “->” and the “dereferencing” operators to accessing node members. o Understand and be able to implement standard linked list operations such as insertion, removal, retrieval, and simple traversal using pointer implementation. o Understand and be able to use “delete” in the implementation of list methods based on pointer implementation. o Understand different performance issues when implementing a list structure using array and pointer.

Remark: For problems in which we give you code, be able not only to state what happens when the code executes, but also be able to locate bugs in the code.

Hints

  • Be sure to read and study the Chapter Summary , Self-Test Exercises , and Programming projects throughout the chapter of Savitch. (The Programming Problems are usually less helpful when studying for exams, however.)
  • Read, execute, and be sure you understand the codes in your lecture notes.