Lecture # 7 Spreadsheet Basics
I have two coins in my hand that total 55¢. One is not a nickel. What are the two coins?
Today Questions: From notes/reading/life? Review Quiz # 1 1.Introduce: How do solve problems? 2.Explain: Formulas, Expressions, Numerical Limits, Formatting, Moving things, Functions Dynamic Recomputation, Records 3.Demo: Spreadsheet Magic – follow along on laptop 4.Practice: You solve a problem with a spreadsheet 5.Evaluate: Share and evaluate your solution 6.Re-practice:Create a Budget with a spreadsheet Review Spreadsheet Functions Understand Dynamic Recomputation
Today Questions: From notes/reading/life? Review Quiz # 1 1.Introduce: How do solve problems? 2.Explain: Formulas, Expressions, Numerical Limits, Formatting, Moving things, Functions Dynamic Recomputation, Records 3.Demo: Spreadsheet Magic – follow along on laptop 4.Practice: You solve a problem with a spreadsheet 5.Evaluate: Share and evaluate your solution 6.Re-practice:Create a Budget with a spreadsheet Review Spreadsheet Functions Understand Dynamic Recomputation
A Problem: Wages = $6.25 per hour Hours worked = 25 Compute the total pay:
What are some ways to solve this problem?
Paper and Pencil
Use a calculator
Write a Program Wages = 6.25; HoursWorked = 25; Total Pay = 6.25 * 25 Wages$6.25 HoursWorked TotalPay
Write a Program Wages = 6.25; HoursWorked = 25; Total Pay = 6.25 * 25 Wages$6.25 HoursWorked25 TotalPay
Write a Program Wages = 6.25; HoursWorked = 25; Total Pay = 6.25 * 25 Wages$6.25 HoursWorked25 TotalPay$156.25
Use a Spreadsheet
Spreadsheets The program that created the modern personal computer.
Today Questions: From notes/reading/life? Review Quiz # 1 1.Introduce: How do solve problems? 2.Explain: Formulas, Expressions, Numerical Limits, Formatting, Moving things, Functions Dynamic Recomputation, Records 3.Demo: Spreadsheet Magic – follow along on laptop 4.Practice: You solve a problem with a spreadsheet 5.Evaluate: Share and evaluate your solution 6.Re-practice:Create a Budget with a spreadsheet Review Spreadsheet Functions Understand Dynamic Recomputation
Type any text Type any number
Formulas are Expressions
A spreadsheet is an array B1 is the same as Book1[0,1] B2 is the same as Book1[1,1] Row-Col is the same as Book1[Row-1, Col- ’ A ’ ]
A cell expression is an assignment B4 = B1*B2 is the same as.... Book1[3,1] = Book1[0,1] * Book1[1, 1];
Demo time
Compute Social Security
Compute Payroll costs
Dynamic recomputation the power of a spreadsheet Change this Automatically recompute these
Why not just use a calculator? Change this Automatically recompute these
Fahrenheit to Celsius
Today Questions: From notes/reading/life? Review Quiz # 1 1.Introduce: How do solve problems? 2.Explain: Formulas, Expressions, Numerical Limits, Formatting, Moving things, Functions Dynamic Recomputation, Records 3.Demo: Spreadsheet Magic – follow along on laptop 4.Practice: You solve a problem with a spreadsheet 5.Evaluate: Share and evaluate your solution 6.Re-practice:Create a Budget with a spreadsheet Review Spreadsheet Functions Understand Dynamic Recomputation
Personal Exercise Create a spreadsheet that looks like the following slide Input data and calculate the cost per square foot Play with the costs and square footage to maximize your dollar per square foot given a budget of $75,000 Now make the kitchen 400 square feet and adjust the rest You have 10 minutes
Remodeling budget
How many $ for the microfilm library?
Why the decimal point? Integer Overflow -> Floating Point
Switch to Floating Point
Overflow
Underflow
What Else is Under the Hood? Formatting Moving things around Functions
Formatting Bold, Italic, Underline
If each cell has a value, where is the format stored? AB 1 2 3
Formatting Automatic, Left, Center, Right
Where do we store alignment? AB = Automatic 1 = Left 2 = Center 3 = Right
Why not use Booleans like bold and italic? AB = Automatic 1 = Left 2 = Center 3 = Right
Font Name and Size
Fill Color and Text Color
Cell Contents And there is a lot more
This kind of data structure is called a “record” And there is a lot more
Records (a collection of named things) Student
Records (a collection of named things) Student Student.GPA = 3.6; Student.Address = “ Reams 3 ” ;
Records (a collection of named things) Student Student.GPA = 3.6; Student.Address = “ Reams 3 ” ;
Records (a collection of named things) Student Student.GPA = 3.6; Student.Address = “ Reams 3 ” ;
An Array of Students Students
An Array of Students Students Students[1].Name = “ Ann ” ;
Number Formatting Demo Currency Comma formatted numbers Percents Decimals Format menu
Dates Demo Formatting Arithmetic on dates
What Else is Under the Hood? Formatting Moving things around Functions
Formatting Moving things around Functions What Else is Under the Hood?
Moving Things Cut, Copy, Paste Adding Rows and Columns
Relative Cell References Copy from here Paste to here
Relative Cell References Copy from here Paste to here
Relative Cell References Copy from here Paste to here Add Rows moved to each row index Add Columns moved to each column index
Inserting a column
Inserting a row
Formatting Moving things around Functions What Else is Under the Hood?
Functions Adding more things than arithmetic to expressions A = Min( 10, 20 ); A==10 B = Min(A+4,16); B == 14 C = Max(A+B, Min(200,50) ) C == Max(24,50) == 50
Functions - Demo Min Max Sqrt Sum Average Today
Questions: From notes/reading/life? Review Quiz # 1 1.Introduce: How do solve problems? 2.Explain: Formulas, Expressions, Numerical Limits, Formatting, Moving things, Functions Dynamic Recomputation, Records 3.Demo: Spreadsheet Magic – follow along on laptop 4.Practice: You solve a problem with a spreadsheet 5.Evaluate: Share and evaluate your solution 6.Re-practice:Create a Budget with a spreadsheet Review Spreadsheet Functions Understand Dynamic Recomputation