Presentation is loading. Please wait.

Presentation is loading. Please wait.

Katherine Kampf / kkampf

Similar presentations


Presentation on theme: "Katherine Kampf / kkampf"— Presentation transcript:

1 Katherine Kampf / kkampf
EECS 183 – DISCuSSION 1 Katherine Kampf / kkampf

2 Take a few minutes to get to know each other!

3 About Me Senior in CS-LSA Usually attend the 8:30am lecture
Office Hours are Tuesday 3-6pm Worked at Microsoft as a PM this summer Favorite areas of CS: security and UX design Ask me about: XCode, Mac OS X, interviews/internships/resumes, women in STEM, HKN, working for a big tech company, Parks and Recreation

4 Discussion Format Review of lecture material Sample code/problems
Tips for projects and exams Questions and feedback welcome anytime Let me know if you need any special accommodations or if there is anything I can do to improve your course experience!

5 Office Hours North Campus in the Duderstadt center third floor east side M, W, Th, F 3-8pm and Tues 3-6pm Sometimes additional hours posted on the website Paper signup sheet Schedule posted online OH start and end when they say they do!

6

7 Upcoming Dates Assignment Due Zynate readings Before each lecture
This Friday 9/16 6pm Project 1 Friday 9/23 6pm

8 IDEs and Program Basics
We support Xcode and Visual Studio Detailed installations and project startup instructions on the website Don’t forget to check out the style guide eecs183.org/vs eecs183.org/xcode

9 IDEs and Program Basics
IDEs provide a code editor where you write and edit code This code is sent to a compiler The compiler turns your code into object code

10 What is an algorithm? Specific series of steps used to solve a problem
Counting people in a room Making pasta Finding a page in a book Algorithms vary in efficiency and speed You’ll learn more about this in EECS 203 and 280

11 Which of these are reserved words?
Reminder: reserved words are key words reserved by C++ that have specific meanings and can’t be used as variable names

12

13 cout and cin cout prints to standard output
You always need to add #include <iostream> at the top of your file when using these! This allows access to the iostream library which holds the cin and cout operations cout << cin >> cout prints to standard output cin reads input from the user

14 Variables An element in code that has a specific type and holds or stores values Use descriptive names with these! Can’t be reserved words type name value bool isHungry = true;

15 Data Types Type What is it? Examples int Whole number 6, 42 double
Decimal numbers 5.3, 6.0 char Single character, denoted by single quotes ‘d’, ‘0’, ‘g’, ‘$’ string Collection of multiple characters, denoted with double quotes “Go Blue!”, “EECS 183 rox” bool Holds values true and false false (0), true (1 and any other non-zero number)

16 Sample Program #include <iostream> #include <string>
using namespace std; int main (){ cout << “Enter your name: “ << endl; string users_name; cin >> users_name; cout << “Hello “ << users_name << “!”; cout << endl; return 0; } Output: Enter your name: Katherine Hello Katherine!

17 Operations and Operators
/ % * = -order of operations applies

18 Operations with different types
Types matter in operations! Dividing an integer by an integer results in an integer 3 / 2 = 1 The result is truncated down Dividing an integer by a double or vice versa results in a double 3 / 2.0 = 1.5 6.8 / 2 = 3.4

19 Modulus Operator % This operator gives you the remainder of a division
5 % 2 = 1

20 Modulus Operator % This operator gives you the remainder of a division
5 % 2 = 1 Think about how many times the second number goes into the first 2 % 5?

21 Modulus Operator % This operator gives you the remainder of a division
5 % 2 = 1 Think about how many times the second number goes into the first 2 % 5? 2! Since 2 does not go into 5 at all, you’re left with the original number

22

23

24 Tips for Success Post on Piazza Start early (the CS mantra)
Plan before you code Work with friends Use whiteboards Don’t stress! You’ll do great

25 Questions? Assignment Due Zynate readings Before each lecture
This Friday 9/16 6pm Project 1 Friday 9/23 6pm


Download ppt "Katherine Kampf / kkampf"

Similar presentations


Ads by Google