CSE 190p wrapup Michael Ernst CSE 190p University of Washington.

Slides:



Advertisements
Similar presentations
CS 3500 SE - 1 Software Engineering: It’s Much More Than Programming! Sources: “Software Engineering: A Practitioner’s Approach - Fourth Edition” Pressman,
Advertisements

CSE 331 wrapup CSE 331 University of Washington. CSE 331 goals Enable students to manage complexity ensure correctness write modest programs.
Software Engineering and Design Principles Chapter 1.
Chapter 2: Algorithm Discovery and Design
Reasons to study concepts of PL
Chapter 1 Principles of Programming and Software Engineering.
Describing Syntax and Semantics
Programming Logic and Design, Introductory, Fourth Edition1 Understanding Computer Components and Operations (continued) A program must be free of syntax.
1 ES 314 Advanced Programming Lec 2 Sept 3 Goals: Complete the discussion of problem Review of C++ Object-oriented design Arrays and pointers.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
Chapter 8: Introduction to High-level Language Programming Invitation to Computer Science, C++ Version, Third Edition.
Chapter 8: Introduction to High-Level Language Programming Invitation to Computer Science, C++ Version, Fourth Edition.
Problem Solving Chapter 2. What is an algorithm? n A solution to a problem that is: –Precise –Effective –Terminating.
Computer Science 101 Introduction to Programming.
1 CSC 221: Introduction to Programming Fall 2012 course overview  What did you set out to learn?  What did you actually learn?  Where do you go from.
Using Visual Logic To Teach A First Course In Programming Logic
1 Shawlands Academy Higher Computing Software Development Unit.
Comp 245 Data Structures Software Engineering. What is Software Engineering? Most students obtain the problem and immediately start coding the solution.
Lists in Python.
Testing Michael Ernst CSE 140 University of Washington.
Testing CSE 140 University of Washington 1. Testing Programming to analyze data is powerful It’s useless if the results are not correct Correctness is.
Computer Science 101 Introduction to Programming.
CSE 140 wrapup Michael Ernst CSE 140 University of Washington.
1 The Software Development Process  Systems analysis  Systems design  Implementation  Testing  Documentation  Evaluation  Maintenance.
Introduction Algorithms and Conventions The design and analysis of algorithms is the core subject matter of Computer Science. Given a problem, we want.
Copyright © 2006 The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1 Chapter 2.
CSE 219 Computer Science III Program Design Principles.
Problem Solving using the Science of Computing MSE 2400 EaLiCaRA Spring 2015 Dr. Tom Way.
Programming Life Cycle Problem analysisunderstand the problem Requirements definition specify what program will do High- and low-level designhow it meets.
The development of common partnership and interuniversitary scientific research according to the principle of sustainable development TRAINING COURSE Romania,
The basics of the programming process The development of programming languages to improve software development Programming languages that the average user.
CSE 331 Software Design & Implementation Hal Perkins Autumn 2012 Wrapup 1.
The Software Development Process
1 CS161 Introduction to Computer Science Topic #9.
A-1 © 2000 UW CSE University of Washington Computer Programming I Lecture 21: Course Wrap-up and Look Ahead.
Week 14 Introduction to Computer Science and Object-Oriented Programming COMP 111 George Basham.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
CSE 331 Software Design & Implementation Dan Grossman Spring 2015 Course Victory Lap (Based on slides by Mike Ernst, Dan Grossman, David Notkin, Hal Perkins)
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
CSE 160 Wrap-Up CSE 160 Spring 2015 University of Washington 1.
CSI 1340 Introduction to Computer Science II Chapter 1 Software Engineering Principles.
Testing CSE 160 University of Washington 1. Testing Programming to analyze data is powerful It’s useless (or worse!) if the results are not correct Correctness.
Chapter 1 Software Engineering Principles. Problem analysis Requirements elicitation Software specification High- and low-level design Implementation.
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
1 The Software Development Process ► Systems analysis ► Systems design ► Implementation ► Testing ► Documentation ► Evaluation ► Maintenance.
Higher Computing Science 2016 Prelim Revision. Topics to revise Computational Constructs parameter passing (value and reference, formal and actual) sub-programs/routines,
CSE 130 : Winter 2009 Programming Languages Lecture 11: What’s in a Name ?
CSE 160 Wrap-Up UW CSE 160 Winter Presentations on Thursday 8:30-10:20am, Thursday 3/17 No more than 5 slides (including title slide) Time limit.
Zach Tatlock / Winter 2016 CSE 331 Software Design and Implementation Lecture 24 Wrap Up.
CSC 108H: Introduction to Computer Programming Summer 2012 Marek Janicki.
Principles of Programming & Software Engineering
Code Optimization.
CSC 321: Data Structures Fall 2016
CSE 160 Wrap-Up UW CSE 160 Winter 2017.
C++ Plus Data Structures
CSE 331 Software Design & Implementation
Topic: Functions – Part 2
Introduction to Computer Programming
Testing UW CSE 160 Spring 2018.
CSE 331 Software Design and Implementation
Cracking the Coding Interview
CSE 160 Wrap-Up UW CSE 160 Spring 2018.
How to develop a program
CSE 331 Software Design & Implementation
Testing UW CSE 160 Winter 2016.
MSIS 655 Advanced Business Applications Programming
CSE 331 Software Design & Implementation
Michael Ernst CSE 140 University of Washington
CSE 331 Software Design & Implementation
Presentation transcript:

CSE 190p wrapup Michael Ernst CSE 190p University of Washington

Progress in 9 weeks 9 weeks ago: you knew no programming Goals: – Computational problem-solving – Python programming language – Experience with real datasets – Fun of extracting understanding and insight from data, and of mastery over the computer – Ability to go on to more advanced computing classes Today: you can write a useful program to solve a real problem – You can even pose the problem yourself

A huge thanks to the rest of the staff Bill HoweDun-Yu Hsiao

Why do you care about processing data? The world is awash in data Processing and analyzing it is the difference between success and failure – for a team or for an individual Manipulating and understanding data is essential to: – Astronomers – Biologists – Chemists – Economists – Engineers – Entrepreneurs – Linguists – Political scientists – Zoologists – … and many more!

Python concepts Assignments Variables Types Programs & algorithms Control flow: loops (for), conditionals (if) File I/O Python execution model – How Python evaluates expressions, statements, and programs

Data structures: managing data List Set Dictionary Tuple Graph List slicing (sublist) List comprehension: shorthand for a loop Mutable and immutable data structures – Immutable: easier to reason about, less efficient Distinction between identity and value

Functions Procedural abstraction – avoid duplicated code – the implementation does not matter to the client Using functions Defining functions A function is an ordinary value – assign to variables – in a call, use an expression as the function: myfns[i](arg) Method syntax: put first argument before a period (.) – arg1.methodname(arg2, arg3) – used for “objects” – (period also means “look up variable in a namespace”) f(x) = x 2

Data abstraction Dual to procedural abstraction (functions) A module is: operations An object is: data + operations Clients use the operations, never directly access data The representation of the data does not matter Programmer defines a class. Each instance of a class is an object.

Testing and debugging Write enough tests: – Cover every branch of each boolean expression especially when used in a conditional expression (if statement) – Cover special cases: numbers: zero, positive, negative, int vs. float data structures: empty, size 1, larger Assertions are useful beyond tests Debugging: after you observe a failure – Divide and conquer this is also a key program design concept – The scientific method state a hypothesis; design an experiment; understand results Think first – Be systematic: record everything; have a reason for each action

Recursion Base case: does all the work for a small problem Inductive case: – passes the buck for most of a large problem – does a small amount of work (or none) to the subanswer – returns whole result

Speed of algorithms Affected primarily by number of times you iterate over data “Constant factors” don’t matter (looping 2 times or 3 times) Nested looping matters a lot

Data analysis Statistics – Run many simulations – How uncommon is what you actually saw? Graphing/plotting results

Program design How to write a function: 1.Name, arguments, and documentation string 2.Tests 3.Body/implementation How to write a program: 1.Decompose into parts (functions, modules) Each part should be a logical unit, not too large or small 2.Write each part Define the problem Choose an algorithm In English first; test it via manual simulation Translate into code When necessary, use wishful thinking – Assume a function exists, then write it later – Can test even before you write if, via a stub

There is more to learn Data analysis, data science, and data visualization Scaling up: – larger programs – “big data”: out-of-memory data, parallel programming, … Ensuring correctness – Principled, systematic design, testing, and programming – Coding style Managing complexity – Programming tools: testing, version control, debugging, deployment – GUIs, user interaction – Data structures and algorithms – Working in a team

What you have learned in CSE 190p Compare your skills today to 9 weeks ago Theory: abstraction, specification, design Practice: implementation, testing Bottom line: The assignments would be easy for you today This is a measure of how much you have learned There is no such thing as a “born” programmer! Your next project can be more ambitious Genius is 1% inspiration and 99% perspiration. Thomas A. Edison

What you will learn later Your next project can be much more ambitious Know your limits Be humble (reality helps you with this) You will continue to learn Building interesting systems is never easy Like any worthwhile endeavor Practice is a good teacher Requires thoughtful introspection Don’t learn only by trial and error! Get lots of practice and feedback

What comes next? Classes – Java: CSE 142 (you may skip), CSE 143 – MATLAB, other programming languages Data analysis: classes, research, jobs – In software engineering & programming systems – In any topic that involves software Having an impact on the world – Jobs (and job interviews) – Larger programming projects The purpose of computing is insight, not numbers. Richard W. Hamming Numerical Methods for Scientists and Engineers

Go forth and conquer System building is fun! It’s even more fun when you build it successfully Pay attention to what matters Use the techniques and tools of CSE 190p effectively