04 File Streams - Engineering101...

Info iconThis preview shows pages 1–9. Sign up to view the full content.

View Full Document Right Arrow Icon
Click to edit Master subtitle style Engineering 101 File Streams
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Quote of the Day - Confucius Be not ashamed of mistakes and thus make them crimes.  
Background image of page 2
Announcements n Project 2 is due Friday at  7pm
Background image of page 3

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Don’t Panic! n PC production scenario seems complicated,  but there’s really just a few basic points to  understand n Produce two speeds of PC,  first   fast  then   blazing n When fast is finished, must wait until end of week  to start blazing n Start with 600 fast chips and 200 blazing, receive  same amounts of both at beginning of every week 
Background image of page 4
Divide and Conquer {8 2730C6-647A-6B42-BE0E-D6F62962 4C1} Order Analysis {FC809A61-392D-3146-8EF3-AB9C6CE9E6EB} main Get input Calc results antFast Production PCs per week t Blazing Production Whole weeks eksTo Produce Fast {15791201-3806-F743-827B-03B8 29BFDA3} weeksTo Produce Blazing {C735325B-0547-0B4A-AC21-7B71DA 0D2D3} Present output Extra days Cs on extra days Overall  program Functions and procedures Computational steps
Background image of page 5

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Project 2 Advice n It is  highly  recommended that you test each  function independently before assembling your  final code. n You will have a much easier time if you build  your program piece by piece rather than trying  to write the entire program all at once.
Background image of page 6
min   and  max   functions int min(int a, intb); // returns the lesser of // a and b int productionThisWeek(int perDay, int chips) { // returns the number of PCs producible this week, // given that we can produce at most the specified // number per day, and start with the specified // number of chips on hand return min(7 * perDay, chips ); }
Background image of page 7

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Unit Testing #include <iostream> using namespace std;
Background image of page 8
Image of page 9
This is the end of the preview. Sign up to access the rest of the document.

Page1 / 27

04 File Streams - Engineering101...

This preview shows document pages 1 - 9. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online