COMS W1004 Introduction to Computer Science and Programming in Java

Slides:



Advertisements
Similar presentations
College of Information Technology & Design
Advertisements

CS107: Introduction to Computer Science Lecture 2 Jan 29th.
CHAPTER 2 GC101 Program’s algorithm 1. COMMUNICATING WITH A COMPUTER  Programming languages bridge the gap between human thought processes and computer.
Computer Software & Software Development H&K Chapter 1 Instructor – Gokcen Cilingir Cpt S 121 (June 20, 2011) Washington State University.
1 Module 2: Fundamental Concepts Problems Programs –Programming languages.
Chapter 1: An Introduction to Computer Science Invitation to Computer Science, C++ Version, Third Edition.
What is an algorithm? Informally: An Algorithm is a step by step method for solving a problem. It’s purpose is to break a larger task down so that each.
Lecture 2: Fundamental Concepts
Chapter 2: Algorithm Discovery and Design
1 Module 2: Fundamental Concepts Problems Programs –Programming languages.
CMPUT101 Introduction to Computing(c) Yngvi Bjornsson1 An Introduction to Computer Science Chapter 1 Topics: The Definition of Computer Science Algorithms.
Chapter 2: Algorithm Discovery and Design
COMS W1004 Introduction to Computer Science May 28, 2008.
Chapter 2 The Algorithmic Foundations of Computer Science
Unit 171 Algorithms and Problem Solving  Introduction  Algorithm Design  Algorithm Properties  Algorithm Control Flow  Examples  Comparing Algorithms.
Lecture Notes 1/21/04 Program Design & Intro to Algorithms.
Chapter 16 Programming and Languages: Telling the Computer What to Do.
CS 1400 Chapter 1 Introduction and Background
1 Algorithms and Problem Solving. 2 Outline  Problem Solving  Problem Solving Strategy  Algorithms  Sequential Statements  Examples.
Lecture Notes 8/30/05 Program Design & Intro to Algorithms.
COMS W1004 Introduction to Computer Science May 27, 2009.
Chapter 2: Algorithm Discovery and Design
The Fundamentals: Algorithms, the Integers & Matrices.
An ordered sequence of unambiguous and well-defined instructions that performs some task and halts in finite time Let's examine the four parts of this.
计算机科学概述 Introduction to Computer Science 陆嘉恒 中国人民大学 信息学院
Chapter 2: Algorithm Discovery and Design Invitation to Computer Science, C++ Version, Third Edition.
Invitation to Computer Science, Java Version, Second Edition.
Chapter 10: Compilers and Language Translation Invitation to Computer Science, Java Version, Third Edition.
CS4HS Columbia University Computer Science vs. Computer Programming Adam Cannon Department of Computer Science Columbia University July 7, 2011.
“The study of algorithms is the cornerstone of computer science.” Algorithms Fall 2011.
Property of Jack Wilson, Cerritos College1 CIS Computer Programming Logic Programming Concepts Overview prepared by Jack Wilson Cerritos College.
CPSC 171 Introduction to Computer Science Algorithm Discovery and Design.
CPSC 171 Introduction to Computer Science More Algorithm Discovery and Design.
Chapter 2: General Problem Solving Concepts
1 Section 2.1 Algorithms. 2 Algorithm A finite set of precise instructions for performing a computation or for solving a problem.
Computer Science 210 Computer Organization Course Introduction.
Computer Programming CONTENTS Introduction to Operating Systems Introduction to programming languages Introduction to perl programming language Programming.
Algorithm Discovery and Design Objectives: Interpret pseudocode Write pseudocode, using the three types of operations: * sequential (steps in order written)
8.1 8 Algorithms Foundations of Computer Science  Cengage Learning.
CS 100Lecture 11 Introduction to Programming n What is an algorithm? n Input and output n Sequential execution n Conditional execution Reading: Chapter.
Chapter 2: Algorithm Discovery and Design Invitation to Computer Science.
DEFINITIONS FOR DR. HALVERSON’S CLASSES. DEFINING TERMS A correctly formed DEFINITION of a term consists of 2 parts  Noun – statement of the basic nature.
What Do Computers Do? A computer system is
Algorithms and Problem Solving
Topic: Introduction to Computing Science and Programming + Algorithm
Definition of Computer Science
INTRODUCTION TO PROBLEM SOLVING
Topic: Introduction to Computing Science and Programming + Algorithm
COP 3503 FALL 2012 Shayan Javed Lecture 15
CSIS 104 –Intro. To Computer Science
GC211Data Structure Lecture2 Sara Alhajjam.
Algorithm and Ambiguity
Introduction to Computer Programming
Algorithm and Ambiguity
Lecture 2: Introduction to Algorithms
Foundations of Computer Science
Lecture 2 Introduction to Computer Science (continued)
Program Control using Java - Theory
Introduction to pseudocode
Algorithm Discovery and Design
Introduction to Algorithms and Programming
Programming.
Algorithm and Ambiguity
Introduction to Algorithms - 1
Click to add Text Computers & Instructions. Computers are given instructions in the form of computer programs that are created through the development.
ICT Gaming Lesson 2.
Computer Science 101 Survey of Computer Science
CSC 241: Introduction to Computer Science I
Computer Science 210 Computer Organization
Presentation transcript:

COMS W1004 Introduction to Computer Science and Programming in Java Columbia University Fall 2018

Lecture 1: Introduction Course objectives Course information Textbooks Syllabus Assignments and Grading Academic Honesty Preliminary Definitions Linear Search Pseudocode Reading

Course Objectives Java programming Skills Knowledge of the fundamental concepts in computer science Algorithmic problem solving capabilities

Course Information Course website: www.cs.columbia.edu/~cannon/1004/ Course information may be found on courseworks at: courseworks.columbia.edu Please look there for answers to your questions and make use of the Piazza discussion board.

Preliminary Definitions Algorithm: Dictionary Definition: A procedure for solving a mathematical problem in a finite number of steps that frequently involves repetition of an operation; broadly: a step-by-step method of accomplishing some task.

Preliminary Definitions Algorithm: Textbook Definition: A well-ordered collection of unambiguous and effectively computable operations that when executed produces a result and halts in a finite amount of time.

Preliminary Definitions Computer Science Textbook Definition: The study of algorithms including Their formal and mathematical properties Their hardware realizations Their linguistic realizations Their applications

Your first Algorithm Linear Search: (also called sequential search) Algorithm to determine whether a given name x appears on a list. Input: A list of n ≥1 names A[1], A[2], ... , A[n], and a given name x. Output. The message "Sorry, x is not on the list" if x is not on the list. Otherwise, the message: "x occurs at position i on the list."

Pseudocode A programming language is a notation for specifying instructions that a computer can execute Every (programming) language has a syntax and a semantics Syntax specifies how something is said (grammar) Semantics specifies what it means Pseudocode is an informal programming language with English-like constructs modeled to look like statements in a Java-like language Anyone able to program in any computer language should understand how to read pseudocode instructions. When in doubt just write it out in English.

Your first Algorithm Here are the instructions for linear search written in pseudocode: found = "no"; i=1; while (found == "no" and i <= n) { if (A[i] == x) { found = "yes"; location = i; } i++; if (found == "no") print ("Sorry, " + x + " is not on the list"); else { print (x + " occurs at position " + location + " on the list");

Reading Chapters 1 and 2 in Schneider and Gersting