Review for Midterm Exam

Slides:



Advertisements
Similar presentations
Chapter 2: Basic Elements of C++
Advertisements

Starting Out with C++, 3 rd Edition 1 Chapter 1. Introduction to Computers and Programming.
COSC 120 Computer Programming
1 Lecture 6: Input/Output (II) Introduction to Computer Science Spring 2006.
Computer Science 1620 Accumulators. Recall the solution to our financial program: #include using namespace std; int main() { double balance = ;
Wednesday, 12/11/02, Slide #1 CS 106 Intro to Comp. Sci. 1 Wednesday, 12/11/02  QUESTIONS??  Today: CLOSING CEREMONIES!  HW #5 – Back Monday (12/16)
Wednesday, 10/9/02, Slide #1 CS 106 Intro to CS 1 Wednesday, 10/9/02  QUESTIONS ??  Today:  Discuss HW #02  Discuss test question types  Review 
How to Program in C++ CHAPTER 3: INPUT & OUTPUT INSTRUCTOR: MOHAMMAD MOJADDAM.
CSCI/CMPE 4341 Topic: Programming in Python Chapter 3: Control Structures (Part 1) – Exercises 1 Xiang Lian The University of Texas – Pan American Edinburg,
C++ Programming: From Problem Analysis to Program Design, Fifth Edition Chapter 3: Input/Output.
COMP102 – Programming Fundamentals I LA2B (Mon 5-7pm) LA2E (Fri 3-5pm) LA2F (Fri 5-7pm) TA: Jackie Lo.
Chapter 3: Input/Output
Admin Office hours 2:45-3:15 today due to department meeting if you change addresses during the semester, please unsubscribe the old one from the.
Program Input and the Software Design Process ROBERT REAVES.
Copyright 2003 Scott/Jones Publishing Brief Version of Starting Out with C++, 4th Edition Chapter 1 Introduction to Computers and Programming.
Due Dates Quiz 1, 2 : Friday September 11 th Quiz 3 : Friday September 18 th Quiz 4 : Monday September 28 th Lab 1, 2 and 3 : Friday Sep 11 th Project.
Selection Statements in C++ If Statement in C++ Semantics: These statements have the same meaning as in the algorithmic language. 2- Two way selection:
C++ Programming: Program Design Including Data Structures, Fifth Edition Chapter 3: Input/Output.
Instructor - C. BoyleFall Semester
CIS-165 C++ Programming I CIS-165 C++ Programming I Bergen Community College Prof. Faisal Aljamal.
C++ Programming: From Problem Analysis to Program Design, Fourth Edition Chapter 3: Input/Output.
CSC1201: PROGRAMMING LANGUAGE 2 Aseel Al Hadlaq 2nd Term
Lecture #6 OPERATORS AND ITS TYPES By Shahid Naseem (Lecturer)
Lecture #5: iostream functions دوال الإدخال والإخراج Dr. Hmood Al-Dossari King Saud University Department of Computer Science 4 March 2012.
CSC1201: Programming Language 2 Lecture 1 Level 2 Course Nouf Aljaffan (C) CSC 1201 Course at KSU1.
Control Structures (B) Topics to cover here: Sequencing in C++ language.
Chapter 3: Input/Output
Review for Final Exam. Contents 5 questions (20 points each) + 1 bonus question (20 points) – Basic concepts in Chapters 1-4 – Chapters 5-9 – Bonus: Chapter.
Chapter 3: Input/Output. Objectives In this chapter, you will: – Learn what a stream is and examine input and output streams – Explore how to read data.
CS 1428 Exam I Review. Exam Format 130 Total Points – 40 Points Writing Programs – 30 Points Tracing Algorithms and determining results – 20 Points Short.
Introduction to Programming By: Prof. Muhammad Abu Baker Siddique 2 nd Lecture 1.
Chapter 4 Strings and Screen I/O. Objectives Define strings and literals. Explain classes and objects. Use the string class to store strings. Perform.
Chapter 3: Input/Output. Objectives In this chapter, you will: – Learn what a stream is and examine input and output streams – Explore how to read data.
Basic concepts of C++ Presented by Prof. Satyajit De
Topic 2 Input/Output.
CS Computer Science IA: Procedural Programming
Basic Elements of C++.
Test Review Computer Science History
EGR 2261 Unit 3 Input/Output Read Malik, Chapter 3.
CS 1428 Exam I Review.
Chapter 1. Introduction to Computers and Programming
CSCI 3328 Object Oriented Programming in C# Review: Final Exam
Basic Elements of C++ Chapter 2.
I Know What I Want to Do – Now What??
Midterm Exam Preperation
Input/Output Handouts: Quiz 2, Unit 3 practice sheets.
CS 1428 Exam I Review.
Programming Funamental slides
Review for Midterm Exam
CSCI 3328 Object Oriented Programming in C# Review: Exam I
Review for Final Exam.
Programming Funamental slides
CSCI 3327 Visual Basic Review: Final Exam
CSCI 3328 Object Oriented Programming in C# Review: Exam I
CSCI 3328 Object Oriented Programming in C# Review: Final Exam
Chapter 3: Input/Output
Chapter 3 Input output.
CSCI 3328 Object Oriented Programming in C# Review: Final Exam
Review for Midterm Exam
Chapter 3: Expressions and Interactivity
Review for Midterm Exam
CS 1428 Final Exam Review.
Review for Final Exam.
Review for Midterm Exam
CSCI 3328 Object Oriented Programming in C# Review: Final Exam
Review of C++ Language Basics
Fundamental Programming
CS 1428 Exam I Review.
CSCI 3328 Object Oriented Programming in C# Review: Exam I
Presentation transcript:

Review for Midterm Exam CSCI 1380

Contents 5 questions (20 points each) + 1 bonus question (20 points) Chapters 1~4 Question types Write down the output of the code Write the code Debug errors in the code Review Lecture slides Exercises (1)~(5) in class (on the course Web page) Review problems

Time & Place & Event 5:45pm ~ 7:00pm, Feb. 28, Tuesday ENGR 1.262 Closed-book exam You can take a piece of cheating paper with A4 size Write down whatever that you think is important (on both sides) with any font size

Chapter 1: An Overview of Computers and Programming Languages Computer system has hardware and software Various kinds of languages, such as machine language, assembly, high-level Algorithm: step-by-step problem-solving process; solution in finite amount of time Object-oriented design (OOD): a program is a collection of interacting objects C++ is an object-oriented programming language

Chapter 2: Basic Elements of C++ Special symbols, keywords, rules of identifiers Basic data types int, float, double, char, string Operators Arithmetic operators and their precedence +, -, *, /, %, +=, -=, *=, /= Increment/decrement operator ++, -- Declaration of variables int first=13, second=10; char ch=' '; Input/Output statement cin and cout

Chapter 3: Input/Output Declaration of input/output stream Usage of cin and cout (as well as other istream/ostream variables) The stream extraction operator, cin>> Syntax and meaning of functions cin.get(varChar); cin.ignore(intExp, chExp); cin.putback(ch) cin.peek(ch) getline(cin, str); See examples in lecture slides

Chapter 3: Input/Output (cont'd) The stream insertion operator, cout<< endl setprecision, showpoint, setw, setfill File stream Header: fstream

Chapter 4: Control Structures I (Selection) Relational operators and precedence Comparison operators <, <=, >, >=, ==, != String comparison Logical operators &&, | | Evaluation of logical expression See examples in lecture slides

Chapter 4: Control Structures I (Selection, cont'd) Syntax and usage of the selection structure One-way selection: if () { } Compound statements Two-way selection: if () { } else { } Multi-way selection: switch () { } Nested if statement See examples in lecture slides

Good Luck! Q/A