DOC PREVIEW
Princeton COS 226 - Lecture

This preview shows page 1 out of 4 pages.

Save
View full document
View full document
Premium Document
Do you want full access? Go Premium and unlock all 4 pages.
Access to all documents
Download any document
Ad free experience
Premium Document
Do you want full access? Go Premium and unlock all 4 pages.
Access to all documents
Download any document
Ad free experience

Unformatted text preview:

Algorithms in Java, 4th Edition·Robert Sedgewick and Kevin Wayne·Copyright © 2009·January 30, 2010 9:44:18 AMAlgorithms and Data StructuresPrinceton UniversitySpring 2010Robert SedgewickCOS 226Algorithms in Java, 4th Edition·Robert Sedgewick and Kevin Wayne·Copyright © 2009·January 30, 2010 9:44:18 AMCourse Overview‣outline‣why study algorithms?‣usual suspects‣coursework‣resources3What is COS 226?•Intermediate-level survey course.•Programming and problem solving with applications.•Algorithm: method for solving a problem.•Data structure: method to store information.topicdata structures and algorithmsdata typesstack, queue, union-find, priority queuesortingquicksort, mergesort, heapsort, radix sortssearchinghash table, BST, red-black treegraphsBFS, DFS, Prim, Kruskal, DijkstrastringsKMP, regular expressions, TST, Huffman, LZWgeometryGraham scan, k-d tree, Voronoi diagramCOS 226 course overview4Their impact is broad and far-reaching.Internet. Web search, packet routing, distributed file sharing, ... Biology. Human genome project, protein folding, ...Computers. Circuit layout, file system, compilers, ...Computer graphics. Movies, video games, virtual reality, ...Security. Cell phones, e-commerce, voting machines, ...Multimedia. CD player, DVD, MP3, JPG, DivX, HDTV, ...Transportation. Airline crew scheduling, map routing, ...Physics. N-body simulation, particle collision simulation, ...…Why study algorithms?Old roots, new opportunities.•Study of algorithms dates at least to Euclid.•Some important algorithms werediscovered by undergraduates!5300 BCE1920s1940s1950s1960s1970s1980s1990s2000sWhy study algorithms?6To solve problems that could not otherwise be addressed.Ex. Network connectivity. [stay tuned]Why study algorithms?7For intellectual stimulation.Why study algorithms?“ For me, great algorithms are the poetry of computation. Just like verse, they can be terse, allusive, dense, and even mysterious. But once unlocked, they cast a brilliant new light on some aspect of computing. ” — Francis Sullivan“ An algorithm must be seen to be believed. ” — D. E. KnuthThey may unlock the secrets of life and of the universe.Computational models are replacing mathematical models in scientific inquiry.820th century science(formula based)! E = mc2! F = ma! F = G m1m2r2 ! "h22m#2+ V (r)$ % & ' ( ) *(r) = E *(r)Why study algorithms?“ Algorithms: a common language for nature, human, and computer. ” — Avi Wigderson21st century science(algorithm based)for (double t = 0.0; true; t = t + dt) for (int i = 0; i < N; i++) { bodies[i].resetForce(); for (int j = 0; j < N; j++) if (i != j) bodies[i].addForce(bodies[j]); }For fun and profit.9Why study algorithms?•Their impact is broad and far-reaching.•Old roots, new opportunities.•To solve problems that could not otherwise be addressed.•For intellectual stimulation.•They may unlock the secrets of life and of the universe.•For fun and profit.10Why study algorithms?Why study anything else?11Lectures. Introduce new material.Precepts. Discussion, problem-solving, background for programming assignment.FAQ.•Not registered? Change precept? Use SCORE.•See Donna O’Leary (CS 210) to resolve serious conflicts. Orientation precept (if you have not taken COS 126): W 2/3 5PM room TBAThe usual suspectsWhatWhenWhereWhoOffice HoursL01MW 11-12:20CS 104Prof. SedgewickW 1:30-2:30P01Th 12:30Friend 108Charlse VaskeTh 3-4P01ATh 12:30Friend 109Maia Ginsburg (lead)see web pageP03Th 3:30Friend 108Prof. RusinkiewiczM 2-3P02F 11Friend 108Berk Kapicioglusee web pageP02AF 11Friend 109Linjie LuoF 1:30-2:30first precept meets this week“all questions answered” during break128 programming assignments. 45%•Electronic submission.•Due 11pm, starting Tuesday 2/9.Exercises. 15%•Due at beginning of lecture, starting Monday 2/8.Exams.•Closed-book with cheatsheet.•Midterm. 15%•Final. 25%Staff discretion. To adjust borderline cases.FinalMidtermProgramsCoursework and gradingeveryone needs to meet me in office hoursExercisesCourse content.•Course info.•Exercises.•Lecture slides.•Programming assignments.•Submit assignments.Booksites. •Brief summary of content.•Download code from lecture.13Resources (web)http://www.princeton.edu/~cos226http://www.cs.princeton.edu/IntroProgramminghttp://www.cs.princeton.edu/algs4Required readings.•Algorithms 4th edition, preliminary edition. [Labyrinth books]•Algorithms in Java, 3rd edition, Parts 1–5. [stay tuned for selections online]•Algorithms in C, 2nd edition. [stay tuned for selections online]Recommended Java reference.•Introduction to Programming in Java. [Labyrinth books]14Resources (books)ROBERT SEDGEWICK | KEVIN WAYNEFOURTH


View Full Document

Princeton COS 226 - Lecture

Documents in this Course
QUICKSORT

QUICKSORT

14 pages

QUICKSORT

QUICKSORT

55 pages

STRINGS

STRINGS

69 pages

STRINGS

STRINGS

18 pages

Hashing

Hashing

7 pages

MERGESORT

MERGESORT

14 pages

Quicksort

Quicksort

12 pages

Strings

Strings

10 pages

Overview

Overview

15 pages

Hashing

Hashing

13 pages

Mergesort

Mergesort

15 pages

Tries

Tries

13 pages

Final

Final

12 pages

Final

Final

12 pages

Mergesort

Mergesort

13 pages

Final

Final

10 pages

Load more
Download Lecture
Our administrator received your request to download this document. We will send you the file to your email shortly.
Loading Unlocking...
Login

Join to view Lecture and access 3M+ class-specific study document.

or
We will never post anything without your permission.
Don't have an account?
Sign Up

Join to view Lecture 2 2 and access 3M+ class-specific study document.

or

By creating an account you agree to our Privacy Policy and Terms Of Use

Already a member?