1
|
- Richard C. Davis
UW CSE – 9/27/2006
- Lecture 1 – Course Introduction
|
2
|
- Main Goal: development skill & confidence
- Run with arbitrary programming problems
- For future in CSE
- For summer jobs, internships, or research
- Skill categories
- Quickly master new tools and languages
- Distinguish good and bad design
- Understand ethical implications
|
3
|
- Overview and Motivation
- Mechanics
- Staff and resources
- Evaluation
- General Advice
- Dive into the command shell
- Homework 0
|
4
|
- New course (since Spring 03)
- Show you the path to expertise
- Amorphous set of things
- Knowing them empowers you
- Most developers learn as they go
|
5
|
- Use the command-line
- Text-based manipulation of environment
- Powerful utility programs (files and strings)
- Scripts for automation
- Quick-and-dirty way to avoid work!
- Tools
- Linux (an operating system)
- Bash (a shell)
|
6
|
- C
- “The” language for OS, networking, embedded
- Manual resource management
- Trust programmer, even when shooting himself in the foot
- “Lower level” programming view
- C++
- Object-oriented brother of C
- “An abomination”
- But heavily used in industry
|
7
|
- Compilers (vs. interpreters)
- Debuggers
- Profilers
- Linkers
- Version control systems
- …
|
8
|
- Needed for BIG projects
- Team programming concepts
- Testing methodologies
- Defensive programming
|
9
|
- Technology
- It’s not good, it’s not evil, and it’s not neutra=
l
- It confronts society
- Why it matters to us
- We vote by choosing what we work on
- We understand technology better than most politicians, lawyers and
philosophers
- Examples
- Patents, privacy, DRM, licensing, censorship
|
10
|
- Teaching Staff (use us)
- Richard Davis, Instructor (Berkeley)
- Lincoln Ritter, TA (UW)
- Mohamed El-Zohairy (UW ugrad)
- Course activities
- Lectures: outline only
- Assignments: where the learning happens
- Office hours: use them
- Weekly study session?
|
11
|
- 20% Midterm
- 20% Final
- 50% Assignments (7)
- 2 on shells and shell scripting
- 2 on C
- 1 on C++
- 2 on programming tools & methods (C++)
- 10% Short paper on society and ethics
|
12
|
- Individual, unless noted
- Collaborate
- Work together
- Point each other to documentation any time
- Don’t look at others’ solutions
- Gilligan’s Island Rule
- Late Policy: 3 “late” days total
- Extra Credit: don’t kill yourself over it
|
13
|
- Read the course policy very carefully
- Always explain unconventional actions
- Honest work is vital for a University
- I trust you completely
- I have no sympathy for trust violations,
nor should you
- Fine line: looking at code is useful!
|
14
|
- http://www.cs.washington.edu/303
- > Mailing list
- > Staff
- > Computing resources
- > Wiki
- > Assignments
- > Schedule
|
15
|
- Strongly Recommended texts:
- Linux Pocket Guide by Daniel J. Barett, O’Reilly, 2004.
- Programming in C (3rd Edition) by Stephen G. Kochan, Sam=
s,
2005
- C++ for Java Programmers by Mark Allen Weiss, Pearson Prentice Hall,
2004
- Lecture Notes
- Other web sites
- Man pages
|
16
|
- Expect not to learn everything
- Get a sense of most important concepts
- Remember where to go for more info
- Lectures alone are not enough
- Your skill will increase with experience
- Don’t spin your wheels
- Ask questions (during and after class)
|
17
|
- Goal: maturity and efficiency
- Command-line
- C/C++
- Programming tools
- Software development concepts
- Social/ethical implications of computing
- This class is just the beginning
- You will learn throughout your career
|
18
|
- Login -> shell
- A program
- Works with operating system (OS)
- User issues commands
- To manipulate files
- To manipulate other programs
- To control other programs
|
19
|
- Filesystem is a tree (actually a DAG)
- The top is /
- Interior nodes are directories
- Directories contain
- Examples
- /home/iws/rcdavis – my “home” directory
- /home/iws/rcdavis/foo.txt – a file
|
20
|
- Special directory names
- Root =3D /
- Current (working) directory =3D .
- Parent directory =3D ..
- User’s home directory =3D ~
- Path examples
- Absolute: /homes/iws/rcdavis
- Relative: ../iws, iws/rcdavis, ~/..
|
21
|
- Directory Navigation: cd, pwd, ls, ls -l
- File Control: mv, cp, rm
- Dir. Control: mkdir, rmdir, cp –r, rm –rf
- Viewing files: cat, head, tail, less
|
22
|
- Us dinosaurs like it J
- Experts can go faster
- Simpler/faster remote login
- Changes less often that GUIs
- Provides programmability
- Most Developers use both
- Find both on Windows, Mac OS X, and Unix
|
23
|
- Bad News:
- Names are short, arcane, and numerous
- Good News:
- Most have –help or –-help option
- Man pages: man ls
- Lots of standard options
|
24
|
- Much more complex than vi
- Why do we use it?
- Lots of goodies for programmers
- We will use for all programming & tools
- Why not use an IDE?
- Unix/Emacs allows easier customization
- “Emacs → IDE” easier than “IDE →
Emacs”
- IDEs change more frequently
|
25
|
- Top Eight Commands
- C-g : quit whatever =
is
happening
- C-x C-f :
“find” file (open)
- C-x C-s : save file
- C-x C-w : “write” file (save as)
- C-x C-c : exit emacs
- C-x b : list “buffers” (currently open files)
- C-k : “kill” (cut from cursor to end of line)
- C-y : “yank” (paste)
|
26
|
- The shell model
- Files, users, and processes
- More powerful commands
- Filename metacharacters
- Command history
- Move toward scripting
|
27
|
- Due this Friday, September 29th @ 2PM
- Very easy
- Background Survey
- Mailing List
- Getting Started with Linux
|