600.325/425 Declarative Methods - J. Eisner1 600.325/425 Declarative Methods Prof. Jason Eisner MWF 3-4pm (sometimes 3-4:15)

Slides:



Advertisements
Similar presentations
Lesson 1:Introduction to Programming (Python/Java)
Advertisements

1 CS101 Introduction to Computing Lecture 17 Algorithms II.
 Suppose for a moment that you were asked to perform a task and were given the following list of instructions to perform:
101.  When you communicate with people you use a language that you both understand.  The trick is that the computer does not speak English.  To communicate.
PROGRAMMING Introduction To Programming Definition Types Of Programming Languages Programming Language Paradigm Translator
1-1 Welcome to: CSC225 Introduction to Computer Organization Paul Hatalsky.
INTERNATIONAL CONFERENCE ON NATURAL LANGUAGE PROCESSING NLP-AI IIIT-Hyderabad CIIL, Mysore ICON DECEMBER, 2003.
How do we make our Welcome.java program do something? The java in our Welcome.java file won’t do anything by itself. We need to tell the computer to execute.
Python Programming Chapter 1: The way of the program Saad Bani Mohammad Department of Computer Science Al al-Bayt University 1 st 2011/2012.
The Binary Machine Modern high-level programming languages are designed to make programming easier. On the other end, the low level, all modern digital.
Computer Concepts 5th Edition Parsons/Oja Page 546 CHAPTER 11 Software Engineering Section A PARSONS/OJA Computer Programming.
CS 300 – Lecture 20 Intro to Computer Architecture / Assembly Language Caches.
Chapter 16 Programming and Languages: Telling the Computer What to Do.
CS 201 Functions Debzani Deb.
CS350/550 Software Engineering Lecture 1. Class Work The main part of the class is a practical software engineering project, in teams of 3-5 people There.
Linked lists and memory allocation Prof. Noah Snavely CS1114
Introduction to a Programming Environment
CSE305 Programming Languages Notes are based primarily on Sebesta text. Quotes are from Sebesta text, unless otherwise noted. Sources other than Sebesta.
Programming. Software is made by programmers Computers need all kinds of software, from operating systems to applications People learn how to tell the.
Programming Concepts and Languages Chapter 12 – Computers: Understanding Technology, 3 rd edition 1November
Programming a computer. What does programming a computer mean ? Programming a computer: Since a computer can only execute machine instructions (encoded.
CS190/295 Programming in Python for Life Sciences: Lecture 1 Instructor: Xiaohui Xie University of California, Irvine.
CSSE 533 – Database Systems Week 1, Day 1 Steve Chenoweth CSSE Dept.
The computer memory and the binary number system.
Powered by DeSiaMore1 Programming Concepts David T. Makota Department of Computing & Information Technology (CIT) The Institute of Finance Management Dar.
DCT 1123 PROBLEM SOLVING & ALGORITHMS INTRODUCTION TO PROGRAMMING.
CCSA 221 Programming in C CHAPTER 2 SOME FUNDAMENTALS 1 ALHANOUF ALAMR.
Programming Languages – Coding schemes used to write both systems and application software A programming language is an abstraction mechanism. It enables.
Programming Languages: Telling the Computers What to Do Chapter 16.
Created by NW 2012 – please note all copyright on images used is property of copyright holder. Note: some of the more complicated descriptions are taken.
Abstraction IS 101Y/CMSC 101 Computational Thinking and Design Tuesday, September 17, 2013 Carolyn Seaman University of Maryland, Baltimore County.
High level & Low level language High level programming languages are more structured, are closer to spoken language and are more intuitive than low level.
COMPUTER PROGRAMMING Source: Computing Concepts (the I-series) by Haag, Cummings, and Rhea, McGraw-Hill/Irwin, 2002.
Programming. What is a Program ? Sets of instructions that get the computer to do something Instructions are translated, eventually, to machine language.
Programming Paradigms
Introduction By: Dr. Javad Razjouyan. Programming Languages.
Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display. 1-1 Welcome to: CSC225 Introduction to Computer Organization.
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
Invitation to Computer Science, Java Version, Second Edition.
Goals of Course Introduction to the programming language C Learn how to program Learn ‘good’ programming practices.
Introduction CSE 1310 – Introduction to Computers and Programming Vassilis Athitsos University of Texas at Arlington 1.
CMPE13Cyrus Bazeghi 1 Programming Languages Telling computers what to do.
Abstraction IS 101Y/CMSC 101 Computational Thinking and Design Tuesday, September 17, 2013 Marie desJardins University of Maryland, Baltimore County.
CS 1308 Computer Literacy and The Internet Software.
Guide to Programming with Python Chapter One Getting Started: The Game Over Program.
Robert Crawford, MBA West Middle School.  Explain how the binary system is used by computers.  Describe how software is written and translated  Summarize.
Unit Testing Maintaining Quality. How do you test? Testing to date…
CSC Intro. to Computing Lecture 12: PALGO. Announcements Homework #3 solutions available  Download from Blackboard/web Quiz #3 will be in class.
Introduction 1 (Read Chap. 1) What is Programming? For some given problem: design a solution for it -- identify, organize & store the problem's data --
Programming Languages
Summary CGS 3460, Lecture 43 April 26, 2006 Hen-I Yang.
27-Jan-16 Analysis of Algorithms. 2 Time and space To analyze an algorithm means: developing a formula for predicting how fast an algorithm is, based.
Georgia Institute of Technology Speed part 1 Barb Ericson Georgia Institute of Technology May 2006.
The Last Lecture CS 5010 Program Design Paradigms "Bootcamp" Lesson © Mitchell Wand, This work is licensed under a Creative Commons Attribution-NonCommercial.
The single most important skill for a computer programmer is problem solving Problem solving means the ability to formulate problems, think creatively.
CS 177 Recitation Week 1 – Intro to Java. Questions?
Representation of Data - Instructions Start of the lesson: Open this PowerPoint from the A451 page – Representation of Data/ Instructions How confident.
Welcome to OBJECT ORIENTED PROGRAMMING Prepared By Prepared By : VINAY ALEXANDER PGT(CS) KV jhagrakhand.
CSC141 Introduction to Computer Programming Programming Language.
Compilers Principles, Techniques, & Tools Taught by Jing Zhang
Lesson 2: Building Blocks of Programming
High Level Programming Languages
CS 179 Project Intro.
Prof. Jason Eisner MWF 3-4pm (sometimes 3-4:15)
Programming.
Welcome to: CSC225 Introduction to Computer Organization
Tonga Institute of Higher Education IT 141: Information Systems
Tonga Institute of Higher Education IT 141: Information Systems
Compilers Principles, Techniques, & Tools Taught by Jing Zhang
Week 1 - Friday COMP 1600.
Presentation transcript:

/425 Declarative Methods - J. Eisner /425 Declarative Methods Prof. Jason Eisner MWF 3-4pm (sometimes 3-4:15)

/425 Declarative Methods - J. Eisner 2 What is this course about? What do you learn in a programming course?  How to use a language (e.g., Java) to solve problems  How the computer actually executes that language (Why do you need to know this?) Ok, this is a programming course  We’ll survey several languages  But they aren’t normal languages!

/425 Declarative Methods - J. Eisner 3 Low-level vs. high-level languages One common language Can do anything (Turing-complete) Low-level: Long, detailed programs written by anal-retentive programming gurus Compiler has limited freedom because you told it exactly what to do Assembler C FORTRAN Lots of different tasks Programmer has freedom to write anything. Hopefully has a lot of free time, too.

/425 Declarative Methods - J. Eisner 4 Useful basic classes Written by other people More abstract classes Interface is closer to how you think about the task Low-level vs. high-level languages Java, C++, OCaml … Lots of different tasks Compiler has limited freedom because someone told it exactly what to do As before, but better organized Reusable building blocks (objects or modules) Building up high-level objects from low-level ones But language and compiler are still low-level

/425 Declarative Methods - J. Eisner 5 Low-level vs. high-level languages Really high level! Programming for the masses! Boy, wouldn’t you like to write this compiler? (take NLP) (and Algorithms) English and its obscure variants (Hindi, Chinese, German, …) A higher-level language that can also do anything (Turing-complete) optimizing

/425 Declarative Methods - J. Eisner 6 Low-level vs. high-level languages “On each line, replace every third word by x’s, then sort the words by length …” It would have to know an awful lot of concepts (line, word, third, sort, length). Maybe just make a big library of specialized objects for those concepts? Some of those objects would need to have pretty powerful methods: “Schedule the classes to minimize time conflicts.” Could we make a formal English- like language ? A higher-level language that can also do anything (Turing-complete)

/425 Declarative Methods - J. Eisner 7 Low-level vs. high-level languages A lot of the same kinds of stuff over and over, actually So maybe it is good to build some powerful, general, reusable objects to handle cases that are either common or hard Then you don’t waste your time doing the same kind of thing again & again And you don’t waste your time figuring out how to do something new & hard What would people write in here anyway? Another language that can do anything (Turing-complete)

/425 Declarative Methods - J. Eisner 8 Low-level vs. high-level languages A lot of the same kinds of stuff over and over, actually So maybe it is good to build some powerful, general, reusable objects to handle cases that are either common or hard Then you don’t waste your time doing the same kind of thing again & again And you don’t waste your time figuring out how to do something new & hard SQL or Datalog Several specialized high-level languages “Tools for the job” Regexp patterns Constraint programs Solvers: general algorithms (sometimes can choose among several wildly different solvers)

/425 Declarative Methods - J. Eisner 9 Low-level vs. high-level languages SQL or Datalog Several specialized high-level languages “Tools for the job” Regexp patterns Constraint programs Solvers: general algorithms To tell the database about your problem, use SQL (standard query language). More expressive than calling a database method! Query optimization – might even compile your query into machine code before running it

/425 Declarative Methods - J. Eisner 10

/425 Declarative Methods - J. Eisner 11 Structure of this course Intro material  What are languages? What do they look like?  What’s a declarative language? What’s a solver?  Encoding a problem in a language  Reducing one language to another; NP-hardness Several actual languages. For each:  Week 1: How does this language let me encode interesting problems?  Homework: Encode a real problem and run a solver.  Week 2: What strategies does the solver use to solve arbitrary problems written in the language? Project of your choice (for 425 students)