CS 112 Intro to Computer Science II Sami Rollins Fall 2006.

Slides:



Advertisements
Similar presentations
CS107 Introduction to Computer Science Lecture 3, 4 An Introduction to Algorithms: Loops.
Advertisements

Computer Programming Lab 8.
1 9/13/06CS150 Introduction to Computer Science 1 Type Casting.
CS 106 Introduction to Computer Science I 02 / 18 / 2008 Instructor: Michael Eckmann.
1 9/29/06CS150 Introduction to Computer Science 1 Loops Section Page 255.
Problem Solving and Program Design Programming. COMP102 Prog Fundamentals I : Problem Solving and Program Design/Slide 2 Problem Solving Process l Define.
1 9/29/06CS150 Introduction to Computer Science 1 Loops Section Page 255.
1 9/17/07CS150 Introduction to Computer Science 1 Type Casting.
1 9/28/07CS150 Introduction to Computer Science 1 Loops section 5.2, 5.4, 5.7.
11.3 Function Prototypes A Function Prototype contains the function’s return type, name and parameter list Writing the function prototype is “declaring”
CS150 Introduction to Computer Science 1
The World of Money! The Basics of Money: Coins and Bills.
CS 112 Intro to Computer Science II Sami Rollins Spring 2007.
CS150 Introduction to Computer Science 1
© The McGraw-Hill Companies, 2006 Chapter 5 Arrays.
CS 106 Introduction to Computer Science I 10 / 04 / 2006 Instructor: Michael Eckmann.
In Class Exercises. TV  Think about your television as an object.  You send messages to it using the remote control. What messages can you send?  What.
1 11/8/06CS150 Introduction to Computer Science 1 Arrays Chapter 8 page 477 November 13, 2006.
1 10/9/06CS150 Introduction to Computer Science 1 for Loops.
CS211 Data Structures Sami Rollins Fall 2004.
Arrays Chapter 8 page /24/07CS150 Introduction to Computer Science 1 Arrays (8.1)  One variable that can store a group of values of the same.
CS102 Object-Oriented Intermediate Programming Sami Rollins Spring 2006.
3nd Grade Mathematics Ms. Coleman
Working With Money Yorubah Banks.  Content Area: Mathematics  Grade Level: Grade 2  Summary: The purpose of this power point is to give the students.
MONEY By: Jerrica Graves COINS A penny is copper and worth $0.01 one cent to the dollar. A nickel is silver and worth$0.05 five cents to the dollar.
EXIT © Joyce Gerald EXITMONEY: Determines equivalent values of coins to $0.50. & $1.00 BILL Determines the value of a set of coins up to $0.50 using.
I wonder who has more money…. 1 dollar, 3 nickels, 5 dimes 6 dimes, 3 pennies, 5 quarters 8 pennies, 6 nickels, 3 dimes 2 half dollars, 5 pennies, 8 nickels.
C HANGES (P ROG 600 – 58 T ) AP Computer Science 2010 By: Chia-Hsuan Wu.
Java Building Elements Lecture 2 Instructors: Fu-Chiung Cheng ( 鄭福炯 ) Associate Professor Computer Science & Engineering Tatung University
© Copyright 1992–2005 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Looping Exercises Deciding Which Loop to Use At this.
Chapter 2 Primitive Data Types and Operations F Introduce Programming with an Example  The MyInput class F Identifiers, Variables, and Constants F Primitive.
1 Chapter 2 Primitive Data Types and Operations F Introduce Programming with an Example  The MyInput class F Identifiers, Variables, and Constants F Primitive.
Math Review Show each amount using the fewest number of coins. 98¢ pennies nickels dimes quarters 1.
VARIABLES Introduction to Computer Science 1- COMP 1005, 1405 Instructor : Behnam Hajian
U.S CURRENCY By: Danielle Ritter. DIRECTIONS Next Back Home.
Money By: Rachel Morello Teacher Page Click here!
Money 2 nd Grade Mathematics Miss Marouchoc NEXT.
Money I. Objectives To be able to recognize U.S. coins & the dollar To know the value of each coin & dollar To know how coins are related to each other.
Nikki Keesee.  We will be learning how to count coins  Quarters  Dimes  Nickels  Pennies  Use a decimal point for coins (.)  Use a dollar sign.
Penny Nickel Dime Penny Nickel Dime Quarter Half Dollar.
Who uses it?. We all use money to buy what we need to function in our world. Money Vocabulary Bills Dollars Coins Sliver Dollar Half Dollar Fifty Cent.
Counting Coins. The Basics Quarter 25 cents Dime 10 cents.
Canadian Money. Coins Penny 1 cent 1¢ Nickel 5 cents 5¢
Let’s Learn About Money!
1 By Mrs. Stephanie Estes. 2 Tyler spent 7 dollars and 4 dimes for school supplies. Write this amount with a dollar sign and decimal point. $7.40.
Name the United States Coins Count the Pennies 10 ¢
MATH AND MONEY.
Adding and Subtracting Money! Click on the dollar sign to begin!
$1 Million $500,000 $250,000 $125,000 $64,000 $32,000 $16,000 $8,000 $4,000 $2,000 $1,000 $500 $300 $200 $100 Welcome.
CMSC 150 LOOPS CS 150: Fri 20 Jan Representing DNA AGTCCAGTGTCAA.
CPSC 233 Tutorial 5 February 2 th /3 th, Java Loop Statements A portion of a program that repeats a statement or a group of statements is called.
Money, Money, Money, Money!!!!!!! Counting money is as easy as 1, 2, 3.
2 nd Grade Math Counting Money by Annette Burchett.
Money – Change Combinations &MathLine. Start with each ring representing a penny Money – Change.
1 09/10/04CS150 Introduction to Computer Science 1 What Actions Do We Have Part 2.
Loops Brent M. Dingle Texas A&M University Chapter 6 – Section 6.3 Multiway Branches (and some from Mastering Turbo Pascal 5.5, 3 rd Edition by Tom Swan)
HOW CAN I CONVERT MONEY? MCC.4.MD.1 Money. Conversions ____ pennies = 1 nickel ____ nickels = 1 dime ____ dimes = 1 dollar ____ quarters = 1 dollar.
SECTION 4-1 pp Deposits.
Chapter 1 Introduction to Java
Start your computers and work along with this demonstration
Begin at 5. Count by 5s to 100. Begin at 30. Count by 10s to 150.
k-2 Lesson d: kids as coins Coin Signs
Name the United States Coins
Exercise 2 Main Module Declare Integer dollars String message
Bills Exercise Main Module Declare Integer dollars
Exercise Solution First questions What's output What's input
Arithmetic Operations
CSC 111 Exam 3 Review Fall 2005.
Chapter 2 Primitive Data Types and Operations
Money Math Review.
Presentation transcript:

CS 112 Intro to Computer Science II Sami Rollins Fall 2006

Administrative Information Class web page

A bit about programming… What do you like about programming? What do you want to learn about programming? What do you find most challenging with respect to programming?

Java Review What is an algorithm? What is a class? What is a method? What is a variable? How do you declare a variable? What are the primitive data types in Java? How does an int differ from a String? How does a String differ from a Person object? How do you do input/output in Java?

Java Review What is the precedence of mathematical operators in Java? What is a package? When do you need to use an import statement? What happens to an object if there are no references that point to it? What is an if statement and when might you use one? What are the three types of loops in Java? When would you use each? What is an iterator? What is an array?

Exercises 1.Problem PP2.9 - Write an application that prompts for and reads a double value representing a monetary amount. Then determine the fewest number of each bill and coin needed to represent that amount, starting with the highest (assume that a ten dollar bill is the maximum size needed). For example, if the value entered is 47.63, then the program should print the equivalent amount as: 4 tens, 1 five, 2 ones, 2 quarters, 1dime, 0 nickels, 3 pennies Write your algorithm first!

Exercises 2.Write an application that prompts the user for an integer representing a number of rows and prints the following pattern: ***** **** *** ** *