day11 - The major ideas 1 Example conceptual question...

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

View Full Document Right Arrow Icon
    1 The major ideas
Background image of page 1

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

View Full DocumentRight Arrow Icon
    2 Example conceptual question Consider the following piece of code where a and b are Boolean variables: printf("Hi "); } else if (b) { printf("there!"); } Under what conditions will the code print out only " there! "? Under what conditions will the code print out " Hi there! "?
Background image of page 2
    3 Programming questions No need to write #include<. ..> No need to write srand(time(NULL)); Excessively bad style is not good. Make sure to indent appropriately. Functionality is more important than brevity. Remember, however, that if you're writing way too much, there probably is an easier solution.
Background image of page 3

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

View Full DocumentRight Arrow Icon
  4 Know the difference Return value vs. output Write a function named DisneylandPrice that accepts a person's age (an integer) as a parameter and returns the price that person would have to pay for a ticket to Disneyland. Children age 2 and under, as well as senior
Background image of page 4
Image of page 5
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 04/29/2009 for the course EE 142 taught by Professor Bensollimketkai during the Spring '09 term at Washington State University .

Page1 / 8

day11 - The major ideas 1 Example conceptual question...

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

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