COMP 14 Introduction to Programming Mr. Joshua Stough February 21, 2005 Monday/Wednesday 11:00-12:15 Peabody Hall 218.

Slides:



Advertisements
Similar presentations
CS122 Engineering Computation Lab Lab 1 Bruce Char Department of Computer Science Drexel University Winter 2010.
Advertisements

CSE115: Introduction to Computer Science I Dr. Carl Alphonce 219 Bell Hall Office hours: M-F 11:00-11:
The UNIVERSITY of NORTH CAROLINA at CHAPEL HILL Adrian Ilie COMP 14 Introduction to Programming Adrian Ilie July 5, 2005.
COMS W1004 Introduction to Computer Science June 24, 2009.
COMP 14 Introduction to Programming Mr. Joshua Stough February 16, 2005 Monday/Wednesday 11:00-12:15 Peabody Hall 218.
COMS W1004 Introduction to Computer Science June 25, 2008.
COMP 14 Introduction to Programming Mr. Joshua Stough February 7, 2005 Monday/Wednesday 11:00-12:15 Peabody Hall 218.
11.3 Function Prototypes A Function Prototype contains the function’s return type, name and parameter list Writing the function prototype is “declaring”
COMP 14 Introduction to Programming Mr. Joshua Stough February 2, 2005 Monday/Wednesday 11:00-12:15 Peabody Hall 218.
COMP 14 Introduction to Programming Mr. Joshua Stough February 28, 2005 Monday/Wednesday 11:00-12:15 Peabody Hall 218.
COMP 14 Introduction to Programming Mr. Joshua Stough January 12, 2005 Monday/Wednesday 11:00-12:15 Peabody Hall 218.
COMP 14 Introduction to Programming Miguel A. Otaduy May 20, 2004.
1 Lab Session-6 CSIT-121 Spring 2005 Structured Choice The do~While Loop Lab Exercises.
COMP 110 Introduction to Programming Mr. Joshua Stough September 28, 2007.
COMP 110 Introduction to Programming Mr. Joshua Stough August 22, 2007 Monday/Wednesday/Friday 3:00-4:15 Gardner Hall 307.
GEOMETRY – WEEK 1 (JAN. 6 TH – 10 TH ) Monday – Non-Student Day Tuesday – Introduction; Review for Ch. 6, 1-15 Wednesday – Warm-up 1-5; Notes, Section.
COMP 110 Introduction to Programming Mr. Joshua Stough September 10, 2007.
1 Lab Session-7 CSIT-121 Fall Introducing Structured Choice 4 The do~While Loop 4 Lab Exercises.
©The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 4 th Ed Chapter Repetition Statements.
COMP 110 Introduction to Programming Mr. Joshua Stough September 24, 2007.
ALGEBRA II – Week 1 ( Jan. 6 th – 10 th )  Monday – Non-student Day  Tuesday – Overview; Note sheet 1-17  Wednesday – Warm-up 1-4; Notes, Section 7-1;
CS1101: Programming Methodology Aaron Tan.
CPS 2231 Computer Organization and Programming Instructor: Tian (Tina) Tian.
Practical PHP IDIA Spring 2012 Bridget M. Blodgett.
CS Class 07 Topics –  When software goes wrong  Count controlled loops  Sentential controlled loops  putting it all together Announcements.
An Introduction to Textual Programming
EGR 2261 Unit 5 Control Structures II: Repetition  Read Malik, Chapter 5.  Homework #5 and Lab #5 due next week.  Quiz next week.
Instructor: Tina Tian. About me Office: RLC 203A Office Hours: Wednesday 1:30 - 4:30 PM or .
ECE 264 Object-Oriented Software Development Instructor: Dr. Honggang Wang Fall 2012 Lecture 4: Continuing with C++ I/O Basics.
PYTHON: PART 2 Catherine and Annie. VARIABLES  That last program was a little simple. You probably want something a little more challenging.  Let’s.
Program 6 Any questions?. System.in Does the opposite of System.out.
Textbook Problem Java – An Introduction to Problem Solving & Programming, Walter Savitch, pp.219, Problem 08.
More While Loop Examples CS303E: Elements of Computers and Programming.
1 CSE1301 Computer Programming: Revision. 2 Topics Type of questions What do you need to know? About the exam Exam technique Staff consultation Revision.
CMP 131 Introduction to Computer Programming Violetta Cavalli-Sforza Week 5, Lecture 1 (Monday)
Count and add list of numbers From user input and from file.
CMP 131 Introduction to Computer Programming Violetta Cavalli-Sforza Week 3, Lecture 1.
Algebra II – Week 1 (Jan. 5 th – 9 th ) Monday – Introduction; Textbook, Pgs , 5-43 odd Tuesday – Warm-up; 1-4; Notes, Section 6; Workbook, Pg.
ECE 264 Object-Oriented Software Development Instructor: Dr. Honggang Wang Spring 2013 Lecture 5: Continuing with C++ I/O Basics.
CMP 131 Introduction to Computer Programming Violetta Cavalli-Sforza Week 10.
Before we get started…. First, a few things… Weighted Grading System Programming Style Submitting your assignments… The char and string variable types.
CPSC 217 T03 Week VI Part #2: Midterm Review Session Hubert (Sathaporn) Hu.
LAB SESSION ONE DIMENSIONAL ARRAY.
Count Controlled Loops (Nested) Ain’t no sunshine when she’s gone …
CMP 131 Introduction to Computer Programming Violetta Cavalli-Sforza Week 11.
Class 9_1 Today: More modeling work session Extension: Computer model due as a HW assignment on Tuesday, March 11.
Midterm Exam Topics (Prof. Chang's section) CMSC 201.
CMP 131 Introduction to Computer Programming Violetta Cavalli-Sforza Week 6, Lecture 1 (Monday)
REPETITION MTS3033 OBJECT ORIENTED PROGRAMMING 1.
1 Project 7: Looping. Project 7 For this project you will produce two Java programs. The requirements for each program will be described separately on.
CISC105 – General Computer Science Class 4 – 06/14/2006.
BIT 115: Introduction To Programming Professor: Dr. Baba Kofi Weusijana (say Doc-tor Way-oo-see-jah-nah, Doc-tor, or Bah-bah)
Instructor: Alexander Stoytchev CprE 185: Intro to Problem Solving (using C)
An Introduction to Programming with C++ Sixth Edition Chapter 5 The Selection Structure.
Chapter 3 Using Variables, Constants, Formatting Mrs. UlshaferSept
Chapter 2 More on Math More on Input
COMP 14 Introduction to Programming
Chapter 1 Introduction to Java
Introduction to Python
CMSC201 Computer Science I for Majors Lecture 13 – Midterm Review
The Selection Structure
Chapter 5: Control Structure
CMSC201 Computer Science I for Majors Lecture 13 – Midterm Review
Topics Introduction to Repetition Structures
While loops The while loop executes the statement over and over as long as the boolean expression is true. The expression is evaluated first, so the statement.
Selection CIS 40 – Introduction to Programming in Python
CS 1428 Exam II Review.
Exception Handling.
SELECTIONS STATEMENTS
Data Types and Maths Programming Guides.
Presentation transcript:

COMP 14 Introduction to Programming Mr. Joshua Stough February 21, 2005 Monday/Wednesday 11:00-12:15 Peabody Hall 218

Announcements Added Office Hour –Tian - now 2-6pm Tuesday Program 3 due Wednesday –start now if you haven't already!

Program 3 You aren't responsible for handling any exceptions that might occur due to user input If you accept only uppercase (or only lowercase) characters make sure the user knows that Test your program –make sure the computer eventually chooses all of the shapes

Mid-Term Exam Wednesday, March 3 –if you're not going to be here, you should tell me this week (make-up exam will be different) 150 points Chapters 1-5 Format: –10 true/false (4 points each) –20 multiple choice (4 points each) –2 programming (15 points each) We'll go over a previous exam and look at sample questions next Monday

Next Time in COMP 14 Object-Oriented Design Read: Ch 6 (pgs ) –you don't need to understand anything about JLabel, JButton, etc. Mini-Review –String methods –booleans –anything else? send me by noon Tuesday

Lab a,b pgs (If you didn't finish this Friday) Use nested for loops to print the following table: ABCDE ABCDE

Lab a,b pgs Simulate order processing at a hardware store Allow user to enter item name and price Print item and price to a file called invoice1.dat Sentinel value for item is 999 Sentinel-controlled while loop hammer 9.95 saw shovel 35.40

Lab a,b pgs Ask user for an item using a GUI (UsingGUI.java) Look in invoice1.dat for the item If the item is found, output the price –doesn't have to be formatted to 2 decimal places If the item is not found, tell the user EOF-controlled and flag-controlled while loop

Ch a,b,c pg. 261 Write a program called WhileLoops.java that uses while loops to: –prompt the user to input two integers (make sure that 2nd integer > 1st integer) –print all the odd numbers between 1st integer and 2nd integer –print the sum of the even numbers between 1st integer and 2nd integer

Ch b,c pg. 261 Copy WhileLoops.java to ForLoops.java –don't forget to change the class name Redo parts b and c using for loops instead of while loops

Programming Session 1. lab a,b (pgs ) 2. lab a,b (pgs ) 3. lab a,b (pgs ) 4. programming exercise 8 a,b,c (pg. 261 in textbook) 5. programming exercise 9 b,c (pg. 261)