Introduction to Matlab Programming with Applications

Size: px
Start display at page:

Download "Introduction to Matlab Programming with Applications"

Transcription

1 Introduction to Matlab Programming with Applications Zheng-Liang Lu Department of Computer Science and Information Engineering National Taiwan University Matlab 289 Summer 2017

2 Class Information ˆ The course page is d /matlab.html. ˆ Lecture notes will be uploaded right before class and be modified after class if necessary. ˆ Note that most of the lecture notes are organized in English. ˆ You can contact me by sending messages to ˆ ˆ facebook. Zheng-Liang Lu 1 / 54

3 Prerequisites ˆ No programming experience required. ˆ It would be helpful if you have some. ˆ Linear algebra is strongly recommended. ˆ Matlab refers to Matrix laboratory. ˆ A beautiful and complete theory, widely used in Computer Science. ˆ I promise to keep everything simple in this class. 1 1 Simple is not easy.... Easy is a minimum amount of effort to produce a result.... Simple is very hard. Simple is the removal of everything except what matters.... Read this article. Zheng-Liang Lu 2 / 54

4 Grading Policy ˆ To acquire the certificate, you need at least 70 points in the final score. ˆ For summer/winter short courses: final exam ˆ For regular night courses: final project ˆ Do not worry about these figures. Zheng-Liang Lu 3 / 54

5 Final Project ˆ Topic: no restriction ˆ Requirement: ˆ define your problem ˆ organize algorithms in need ˆ write codes in Matlab (at least) ˆ present your result with a few slides ˆ Goals: ˆ solve a problem by formulating the problem, organizing an algorithm, writing codes, and debugging ˆ get familiar with programming concepts ˆ expand your horizon by asking questions in others work Zheng-Liang Lu 4 / 54

6 Final Exam ˆ On-site programming ˆ 5 questions (more or less) ˆ Open everything 2 2 You should learn how to integrate the tools you use, even if the tools you have are not made on your own. Zheng-Liang Lu 5 / 54

7 1 >> Lecture 0 2 >> 3 >> -- Introduction 4 >> Zheng-Liang Lu 6 / 54

8 What Is Programming? ˆ Programming is the activity of writing a sequence of instructions to tell a machine to perform a specific task. ˆ A sequence of instructions program ˆ A set of well-defined notations is used to write a program programming language ˆ The person who writes a program programmer designer 3 3 Writing codes is not what the CS people work for. We are writing codes to make a better world. Zheng-Liang Lu 7 / 54

9 In Practice ˆ Programming is to provide a solution to a real-world problem using computational models supported by programming languages. ˆ The solution is a program. Zheng-Liang Lu 8 / 54

10 Programs ˆ A program is a sequence of instructions, written in an artificial language, to perform a specified task by a machine. ˆ They are almost everywhere. 4 ˆ For example, ˆ Computer virus ˆ Video games ˆ Operating systems 5 ˆ ATM, traffic light, Google search engine, recommendation system... ˆ Differences: goal, functionality, algorithms, and resources. 4 See 5 For desktops and laptops, you may know Windows, Unix, Linux, and Mac OS. For mobile devices, Windows, Android, and ios are popular. Zheng-Liang Lu 9 / 54

11 How and Where The Programs Run 8 ˆ The programs are activated from the disk into the main memory. ˆ We now call them the processes. 6 ˆ CPUs contain the arithmetic and logic units (ALUs) and the registers (REGs). 7 ˆ ALUs provide the computational power. ˆ REGs supply operands to the ALU and store the results of ALU operations temporarily. ˆ The output is written back to the main memory and further stored into the disk if necessary. 6 The process is a formal terminology used in OS. 7 See Herein ALUs include control units. 8 You may refer to any class for an introduction to computer system. For example, Introduction to Computer Science & Programming in C. Zheng-Liang Lu 10 / 54

12 Memory Hierarchy 9 9 See Figure 1-9 in Bryant, p. 14. Zheng-Liang Lu 11 / 54

13 Programming Languages ˆ A programming language is an artificial language to communicate with machines. ˆ Programming languages syntax and semantics ˆ Recall how you learned the 2nd human language. ˆ How many programming languages in the world? ˆ Top 20 programming languages are listed in TIOBE. ˆ Matlab: top 20. ˆ Note that every language originates from reasons. Zheng-Liang Lu 12 / 54

14 Short History ˆ 1st generation: machine code ˆ 2nd generation: assembly code ˆ 3rd generation: high-level programming languages ˆ Post-3rd generations ˆ Matlab is one of 4th programming languages. Zheng-Liang Lu 13 / 54

15 Zheng-Liang Lu 14 / 54

16 1st-Generation Programming Languages ˆ Computers understand instructions only in binary, which is a sequence of 0s and 1s. (Why?) ˆ Each computer has its own set of instructions. 10 ˆ So the programs at the very early stage were machine-dependent. ˆ These are so-called the machine language, aka machine code. ˆ Pros: ˆ Cons: ˆ Most efficient for machines ˆ Hard to program for human ˆ Not portable ˆ Still widely used in programming lower level functions of the system, such as drivers, interfaces with firmware and hardware. 10 For example, X86 and ARM. Zheng-Liang Lu 15 / 54

17 2nd-Generation Programming Languages ˆ An assembly language uses mnemonics which are easier to recognize and memorize, to represent instructions as opposed to the machine codes. ˆ Hence, the code can be read and written by human programmers. ˆ Yet, it is still machine-dependent. Zheng-Liang Lu 16 / 54

18 ˆ To run on a computer, it must be converted into a machine readable form, a process called assembly. ˆ More often find use in extremely intensive processing such as games, video editing, graphic manipulation/rendering. ˆ Note that machine languages and assembly languages are also known as low-level languages. Zheng-Liang Lu 17 / 54

19 3rd-Generation Programming Languages ˆ The high-level programming languages use English-like words, mathematical notation, and punctuation to write programs. ˆ They are much closer to human languages. ˆ Pros: ˆ Portable, machine-independent ˆ Human-friendly ˆ For example, C 11, C++ 12, and Java Dennis Ritchie (1973). FYI, C is the cornerstone of modern programming languages. If possible, taking C programming course gives you an insight of computer science. 12 Bjarne Stroustrup (1983). 13 James Gosling (1995). Zheng-Liang Lu 18 / 54

20 ˆ Note that the machines understand and execute only the machine codes as before. ˆ The translation is accomplished by a compiler, an interpreter, or a combination of both. Zheng-Liang Lu 19 / 54

21 What Can A Program Do? ˆ A program is an implementation of an algorithm expressed in a specific programming language. Zheng-Liang Lu 20 / 54

22 Algorithms In A Nutshell ˆ Simply put, an algorithm is a procedure that solves a particular class of problems, such as a cookbook. ˆ An algorithm is a well-defined computational procedure that takes a set of values as input and produces a set of values as output. ˆ Note that an algorithm is not necessarily expressed in a specific programming language. ˆ Could be human languages, flow charts, or pseudo codes. Zheng-Liang Lu 21 / 54

23 Properties of Algorithms 14 ˆ An algorithm must possess the following properties: ˆ Input and output ˆ Correctness ˆ Definiteness: basic instructions provided by a machine, e.g. +. ˆ Effectiveness: actions which can be completed by combination of basic instructions. ˆ Finiteness: resource requirement, especially time and space. 14 Donald E. Knuth (1938 ). Zheng-Liang Lu 22 / 54

24 Example ˆ Organize an algorithm that finds the greatest element in the input list, say A. Input: A (a list of n numbers) Output: max (the greatest element in A) ˆ Can you provide a procedure to determine the greatest element? ˆ For all situations? Zheng-Liang Lu 23 / 54

25 Optimal Solution ˆ The first element of A can be fetched by calling A(1). ˆ Let be the assignment operator in the following pseudo code. 1 max <- A(1) 2 for i <- 2 ~ n 3 if A(i) > max 4 max <- A(i) 5 end 6 end 7 return max ˆ How to find the minimal element? ˆ How to find the location of the greatest element? ˆ Why not max 0? Zheng-Liang Lu 24 / 54

26 Computers are good at following instructions, but not at reading your mind. Donald Knuth (1938-) Computer science is no more about computers than astronomy is about telescopes. Edsger Wybe Dijkstra ( ) Zheng-Liang Lu 25 / 54

27 Steps of Developing A Program ˆ Problem formulation: state the problem concisely. ˆ Input: specify the data to be used. ˆ Output: specify the information to be returned. ˆ Modeling and algorithm: work through the solution steps by hands; use a simpler set of data if necessary. ˆ Programming: write and debug the program. ˆ Verification: check the outputs by trying various inputs; a unit test could be necessary. 15 ˆ Generalization: generalize your solution for the purpose of reuse. 15 As to unit test, you may spend as much time as you write the program. Zheng-Liang Lu 26 / 54

28 Alan Turing ( ) Zheng-Liang Lu 27 / 54

29 Alan Turing ˆ Provided a formalization of the concepts of algorithm and universal computation model for general-purpose computers. ˆ The central subject of study in computing theory is Turing machine: ˆ Toy example from Google ˆ Also proved that there exist problems which are undecidable by Turing machines. 16 ˆ Father of computing theory and artificial intelligence 17 ˆ Turing Award of ACM 18 ˆ The Imitation Game (2014) 16 See Halting problem. 17 See Turing test. 18 Association for Computing Machinery Zheng-Liang Lu 28 / 54

30 What is Matlab? ˆ Matlab is a powerful and easy-to-use integrated programming environment, especially for numerical computing. ˆ programmable, matrix computation, fruitful toolboxes 19 available, good memory management, easy to draw graphs... ˆ The only thing you need to provide is Zheng-Liang Lu 29 / 54

31 Algorithms! A screenshot of The Social Network (2010) Zheng-Liang Lu 30 / 54

32 Summary ˆ Program design data structures + algorithms ˆ Data structures: organize your data in an efficient way ˆ Algorithms: process your data so that you can derive the solution ˆ In some sense, we can say that programming languages are less important than the two above. ˆ Here we will learn Matlab programming and classical algorithms. ˆ Additionally, I wish you could capture computational thinking. Zheng-Liang Lu 31 / 54

33 Fathers of Matlab 21 Prof. Cleve Moler Zheng-Liang Lu 32 / 54

34 Jack Little Zheng-Liang Lu 33 / 54

35 MATLAB: An Overview Zheng-Liang Lu 34 / 54

36 Command Window ˆ Let s try a greeting, Hello, Matlab. 1 >> disp('hello, Matlab.'); ˆ disp takes the string as input in the parenthesis, and outputs ˆ A string is single-quoted in Matlab. ˆ The convention in the slides is as follows: ˆ Boxes are the listings for sample programs. ˆ Words and sentences highlighted in red are important. ˆ Words in blue are reserved words. ˆ Bold words in black are functions. Zheng-Liang Lu 35 / 54

37 Errors ˆ Matlab interrupts your program if an error occurs somewhere. ˆ Don t be frustrated by red lines. ˆ Most of these errors which are detected by Matlab are syntax errors and runtime errors, which can be avoided by more practices. ˆ The others are logic errors 22, which cannot be found by the machine itself! 22 Aka semantic errors. Zheng-Liang Lu 36 / 54

38 Why do we fall sir? So that we can learn to pick ourselves up. Alfred Pennyworth, Batman Begins (2005) Zheng-Liang Lu 37 / 54

39 Helpers ˆ The function help followed by the command name shows the usage of that command, for example, 1 >> help disp 2... ˆ The reference page also provides the detail of commands with fruitful examples. ˆ Google is your best friend (when you learn by yourself). Zheng-Liang Lu 38 / 54

40 Zheng-Liang Lu 39 / 54

41 m Files ˆ A script is a complete program which contains the input data and can be executed directly. ˆ A function is a subroutine which may need input data when being called in other programs and functions. ˆ Reuse your code. ˆ Lower the program complexity: abstraction. Zheng-Liang Lu 40 / 54

42 Debut: Your First Matlab Program 1 % This is my first Matlab program. 2 clear; % Clear all variables stored in Workspace. 3 clc; % Clear the screen. 4 % main program 5 disp('hello, world.'); ˆ The lines which begin with % are regarded as the comments which will not be executed. ˆ The function clear is used to release all the variables in the workspace. 23 ˆ The function clc cleans the command window. 23 You may release the variable x by calling clear x. Zheng-Liang Lu 41 / 54

43 ˆ Then we need to save 24 to the script, for example, helloworld.m. ˆ Click the Run button. 25 ˆ If this script is not at the current folder when you execute it, Matlab will offer two options: 1. Change folder 2. Add to Path Pool 26 ˆ You can run this program later, simply by calling helloworld. 1 >> helloworld 2 3 Hello, world. 24 Press ctrl + s. 25 Alternatively, press F5 for saving the file and executing the program. 26 Path Pool is a list of directories where the functions could be. Zheng-Liang Lu 42 / 54

44 Block Comments ˆ Press ctrl + r to comment lines. ˆ Press ctrl + t to de-comment lines which begin with %. ˆ Note that the contiguous comment lines starting from the top of file are regarded as the program document. 1 >> help helloworld 2 3 This is my first Matlab program. ˆ We can easily organize the program by these two hot keys during the trial-and-error stage. Zheng-Liang Lu 43 / 54

45 1 >> Lecture 1 2 >> 3 >> -- Variables, Date Types, and Vectorization 4 >> Zheng-Liang Lu 44 / 54

46 Data Types ˆ Binary digit, aka bit, is a digit whose value is either 0 or ˆ Everything in the machine is encoded in binary. ˆ How many bits do you need to store a zero in the memory? ˆ Not depending on the value itself, but on the type of the variable! 28 ˆ The types determine the size of a variable. ˆ We have two different numeric types: integers and real numbers (more precisely, floating points 29 ). ˆ An int value takes 32 bits. ˆ A double value takes 64 bits FYI, 1 byte contains 8 bits. 28 Use class(x) to check the type of x. 29 IEEE 754 Standard (1985). 30 The type double refers to double-precision floating point. Zheng-Liang Lu 45 / 54

47 Computational Limits ˆ It is a common convention to use e to identify a power of 10, e.g. 1e5 = 100, 000 and 1.2e 5 = Zheng-Liang Lu 46 / 54

48 ˆ The types further determine the possible states. ˆ For example, consider 2 bits for nonnegative integers. ˆ There are 2 2 = 4 possible states, and the greatest value is 3. ˆ By default, Matlab takes every numeric data as double values. ˆ However, the floating points approximate real numbers. ˆ For example, =? (Why?) Zheng-Liang Lu 47 / 54

49 Causes of Numerical Errors 32 ˆ Finite precision of computations involving floating-points 31 ˆ Truncation because simplifications are made to the mathematical equations to make them more amenable to calculation, e.g. the truncation to an infinite series ˆ Loss of significance ˆ For example, is the expression e20 1e20 equal to the expression (1e20 1e20)? (Why?) 31 Read 32 See by Prof. C.-J. Lin. Zheng-Liang Lu 48 / 54

50 Variables and Assignments ˆ A variable is used to keep a value or values. ˆ A box which contains something. ˆ In most languages, a statement looks like var = expression, where var is a variable and expression is any arithmetic operation. 33 ˆ For example, suppose x = 0. ˆ Then run y = x + 1 and so y = 1. (Trivial.) ˆ How about x = x + 1? ˆ Actually, the assignment operator (=) is defined to assign a value to the variable, from right to left. 33 To the best of my knowledge, 1 = x is not allowed because the left-hand side of the assignment should be a space. Zheng-Liang Lu 49 / 54

51 ˆ For example, 1 >> a = 10; 2 >> b = 20; 3 >> a + b 4 5 ans = ˆ The variable ans is used by default if you don t assign one for the immediate result. ˆ If you drop the semicolon (;) in Line 2, then the immediate result will appear in the command window Note that you may not drop semicolons in other programming languages. For example, the semicolon is used as the end symbol of a statement in C, C++, and Java. Zheng-Liang Lu 50 / 54

52 Variable Naming ˆ Cannot begin with a number, e.g. 1x is wrong. ˆ Cannot have blanks, e.g. x 1 is wrong. ˆ Cannot contain +-*\%, e.g. x%1 ˆ Cannot be any of key words, e.g. for ˆ Cannot be the same name as any m-file ˆ Matlab is case-sensitive, e.g. A and a are two distinct letters. Zheng-Liang Lu 51 / 54

53 ˆ Variable names should always be mnemonic. 35 ˆ May use underscores ( ) or use CamelCase. 36 ˆ We avoid to use names of reserved words 37 and built-in functions. ˆ i = 1 and j = 1 by default. ˆ If you set i = 1, then i = 1 until you clear i. ˆ pi and sin are also the names which are not to be overloaded. 35 The length of name is limited to 63 characters. The function namelengthmax returns the maximum length in this machine. 36 See 37 Try iskeyword. Zheng-Liang Lu 52 / 54

54 Scalar Variables ˆ The variable x is said to be a scalar variable if x R 1 or C 1. ˆ The complex field, denoted by C, contains all the complex numbers a + bi, where i = 1, and a, b R. 38 ˆ Try x = 1 + i in the command window. ˆ Usually used for parameters of the problems. ˆ For example, pi is a default variable to store the ratio of a circle s circumference to its diameter. 38 In math, C 1 is equivalent to R 2. So x contains two double values. However, Matlab treats a complex number as an entity. Zheng-Liang Lu 53 / 54

55 Scalar Arithmetic Operators See Table 2.1 Arithmetic Operations Between Two Scalars in Moore, p. 21. Zheng-Liang Lu 54 / 54

AP Computer Science A: Java Programming

AP Computer Science A: Java Programming AP Computer Science A: Java Programming Zheng-Liang Lu Department of Computer Science & Information Engineering National Taiwan University APcomSci 297 Spring 2018 Class Information Instructor: Zheng-Liang

More information

Java Programming. Zheng-Liang Lu. Java 308 Spring Department of Computer Science & Information Engineering National Taiwan University

Java Programming. Zheng-Liang Lu. Java 308 Spring Department of Computer Science & Information Engineering National Taiwan University Java Programming Zheng-Liang Lu Department of Computer Science & Information Engineering National Taiwan University Java 308 Spring 2019 Class Information Instructor: Zheng-Liang Lu Email: d00922011@ntu.edu.tw

More information

Introduction to Matlab Programming with Applications

Introduction to Matlab Programming with Applications Introduction to Matlab Programming with Applications Zheng-Liang Lu Department of Computer Science and Information Engineering National Taiwan University Matlab 256 Summer 2015 Class Information Official

More information

AP Computer Science A

AP Computer Science A AP Computer Science A Zheng-Liang Lu Department of Computer Science and Information Engineering National Taiwan University APcomSciA 268 Summer 2016 Class Information The class website, http://www.csie.ntu.edu.tw/

More information

Java Programming. Zheng-Liang Lu. Java 301 Summer Department of Computer Science & Information Engineering National Taiwan University

Java Programming. Zheng-Liang Lu. Java 301 Summer Department of Computer Science & Information Engineering National Taiwan University Java Programming Zheng-Liang Lu Department of Computer Science & Information Engineering National Taiwan University Java 301 Summer 2018 Class Information Instructor: Zheng-Liang Lu Email: d00922011@csie.ntu.edu.tw

More information

Java Programming. Zheng-Liang Lu. Java 304 Fall Department of Computer Science & Information Engineering National Taiwan University

Java Programming. Zheng-Liang Lu. Java 304 Fall Department of Computer Science & Information Engineering National Taiwan University Java Programming Zheng-Liang Lu Department of Computer Science & Information Engineering National Taiwan University Java 304 Fall 2018 Class Information Instructor: Zheng-Liang Lu Email: d00922011@ntu.edu.tw

More information

Java Programming. U Hou Lok. Java Aug., Department of Computer Science and Information Engineering, National Taiwan University

Java Programming. U Hou Lok. Java Aug., Department of Computer Science and Information Engineering, National Taiwan University Java Programming U Hou Lok Department of Computer Science and Information Engineering, National Taiwan University Java 272 8 19 Aug, 2016 U Hou Lok Java Programming 1 / 78 Class Information Lecturer: U

More information

CMSC 150 LECTURE 1 INTRODUCTION TO COURSE COMPUTER SCIENCE HELLO WORLD

CMSC 150 LECTURE 1 INTRODUCTION TO COURSE COMPUTER SCIENCE HELLO WORLD CMSC 150 INTRODUCTION TO COMPUTING ACKNOWLEDGEMENT: THESE SLIDES ARE ADAPTED FROM SLIDES PROVIDED WITH INTRODUCTION TO JAVA PROGRAMMING, LIANG (PEARSON 2014) LECTURE 1 INTRODUCTION TO COURSE COMPUTER SCIENCE

More information

CITS2401 Computer Analysis & Visualisation

CITS2401 Computer Analysis & Visualisation FACULTY OF ENGINEERING, COMPUTING AND MATHEMATICS CITS2401 Computer Analysis & Visualisation SCHOOL OF COMPUTER SCIENCE AND SOFTWARE ENGINEERING Topic 3 Introduction to Matlab Material from MATLAB for

More information

CS Prof J.P.Morrison

CS Prof J.P.Morrison CS1061 2018-2019 Prof J.P.Morrison C Programming C is the most popular language worldwide. Everything from microcontrollers to operating systems is written in C flexible and versatile, allowing maximum

More information

Variables and Assignments

Variables and Assignments Variables and Assignments ˆ A variable is used to keep a value or values. ˆ A box which contains something. ˆ In most languages, a statement looks like var = expression, where var is a variable and expression

More information

CS2900 Introductory Programming with Python and C++ Kevin Squire LtCol Joel Young Fall 2007

CS2900 Introductory Programming with Python and C++ Kevin Squire LtCol Joel Young Fall 2007 CS2900 Introductory Programming with Python and C++ Kevin Squire LtCol Joel Young Fall 2007 Course Web Site http://www.nps.navy.mil/cs/facultypages/squire/cs2900 All course related materials will be posted

More information

An Introduction to MATLAB See Chapter 1 of Gilat

An Introduction to MATLAB See Chapter 1 of Gilat 1 An Introduction to MATLAB See Chapter 1 of Gilat Kipp Martin University of Chicago Booth School of Business January 25, 2012 Outline The MATLAB IDE MATLAB is an acronym for Matrix Laboratory. It was

More information

Structure Array 1 / 50

Structure Array 1 / 50 Structure Array A structure array is a data type that groups related data using data containers called fields. Each field can contain any type of data. Access data in a structure using dot notation of

More information

BASIC COMPUTATION. public static void main(string [] args) Fundamentals of Computer Science I

BASIC COMPUTATION. public static void main(string [] args) Fundamentals of Computer Science I BASIC COMPUTATION x public static void main(string [] args) Fundamentals of Computer Science I Outline Using Eclipse Data Types Variables Primitive and Class Data Types Expressions Declaration Assignment

More information

Lecture 5: The Halting Problem. Michael Beeson

Lecture 5: The Halting Problem. Michael Beeson Lecture 5: The Halting Problem Michael Beeson Historical situation in 1930 The diagonal method appears to offer a way to extend just about any definition of computable. It appeared in the 1920s that it

More information

TOPIC 2 INTRODUCTION TO JAVA AND DR JAVA

TOPIC 2 INTRODUCTION TO JAVA AND DR JAVA 1 TOPIC 2 INTRODUCTION TO JAVA AND DR JAVA Notes adapted from Introduction to Computing and Programming with Java: A Multimedia Approach by M. Guzdial and B. Ericson, and instructor materials prepared

More information

CSC105, Introduction to Computer Science I. Introduction. Perl Directions NOTE : It is also a good idea to

CSC105, Introduction to Computer Science I. Introduction. Perl Directions NOTE : It is also a good idea to CSC105, Introduction to Computer Science Lab03: Introducing Perl I. Introduction. [NOTE: This material assumes that you have reviewed Chapters 1, First Steps in Perl and 2, Working With Simple Values in

More information

Zheng-Liang Lu Java Programming 45 / 79

Zheng-Liang Lu Java Programming 45 / 79 1 class Lecture2 { 2 3 "Elementray Programming" 4 5 } 6 7 / References 8 [1] Ch. 2 in YDL 9 [2] Ch. 2 and 3 in Sharan 10 [3] Ch. 2 in HS 11 / Zheng-Liang Lu Java Programming 45 / 79 Example Given a radius

More information

last time in cs recitations. computer commands. today s topics.

last time in cs recitations. computer commands. today s topics. last time in cs1007... recitations. course objectives policies academic integrity resources WEB PAGE: http://www.columbia.edu/ cs1007 NOTE CHANGES IN ASSESSMENT 5 EXTRA CREDIT POINTS ADDED sign up for

More information

C H A P T E R 1. Introduction to Computers and Programming

C H A P T E R 1. Introduction to Computers and Programming C H A P T E R 1 Introduction to Computers and Programming Topics Introduction Hardware and Software How Computers Store Data How a Program Works Using Python Computer Uses What do students use computers

More information

7/8/10 KEY CONCEPTS. Problem COMP 10 EXPLORING COMPUTER SCIENCE. Algorithm. Lecture 2 Variables, Types, and Programs. Program PROBLEM SOLVING

7/8/10 KEY CONCEPTS. Problem COMP 10 EXPLORING COMPUTER SCIENCE. Algorithm. Lecture 2 Variables, Types, and Programs. Program PROBLEM SOLVING KEY CONCEPTS COMP 10 EXPLORING COMPUTER SCIENCE Lecture 2 Variables, Types, and Programs Problem Definition of task to be performed (by a computer) Algorithm A particular sequence of steps that will solve

More information

! Learn how to think like a computer scientist. ! Learn problem solving. ! Read and write code. ! Understand object oriented programming

! Learn how to think like a computer scientist. ! Learn problem solving. ! Read and write code. ! Understand object oriented programming 1 TOPIC 1 INTRODUCTION TO COMPUTER SCIENCE AND PROGRAMMING Topic 1 Introduction to Computer Science and Programming Notes adapted from Introduction to Computing and Programming with Java: A Multimedia

More information

Programming 1. Lecture 1 COP 3014 Fall August 28, 2017

Programming 1. Lecture 1 COP 3014 Fall August 28, 2017 Programming 1 Lecture 1 COP 3014 Fall 2017 August 28, 2017 Main Components of a computer CPU - Central Processing Unit: The brain of the computer. ISA - Instruction Set Architecture: the specific set of

More information

Starting with a great calculator... Variables. Comments. Topic 5: Introduction to Programming in Matlab CSSE, UWA

Starting with a great calculator... Variables. Comments. Topic 5: Introduction to Programming in Matlab CSSE, UWA Starting with a great calculator... Topic 5: Introduction to Programming in Matlab CSSE, UWA! MATLAB is a high level language that allows you to perform calculations on numbers, or arrays of numbers, in

More information

LESSON 2 VARIABLES, OPERATORS, EXPRESSIONS, AND USER INPUT

LESSON 2 VARIABLES, OPERATORS, EXPRESSIONS, AND USER INPUT LESSON VARIABLES, OPERATORS, EXPRESSIONS, AND USER INPUT PROF. JOHN P. BAUGH PROFJPBAUGH@GMAIL.COM PROFJPBAUGH.COM CONTENTS INTRODUCTION... Assumptions.... Variables and Data Types..... Numeric Data Types:

More information

CPS122 Lecture: From Python to Java last revised January 4, Objectives:

CPS122 Lecture: From Python to Java last revised January 4, Objectives: Objectives: CPS122 Lecture: From Python to Java last revised January 4, 2017 1. To introduce the notion of a compiled language 2. To introduce the notions of data type and a statically typed language 3.

More information

Midterms Save the Dates!

Midterms Save the Dates! University of British Columbia CPSC 111, Intro to Computation Alan J. Hu Primitive Data Types Arithmetic Operators Readings Your textbook is Big Java (3rd Ed). This Week s Reading: Ch 2.1-2.5, Ch 4.1-4.2.

More information

Computer Programming in MATLAB

Computer Programming in MATLAB Computer Programming in MATLAB Prof. Dr. İrfan KAYMAZ Atatürk University Engineering Faculty Department of Mechanical Engineering What is a computer??? Computer is a device that computes, especially a

More information

Computer Basics 1/6/16. Computer Organization. Computer systems consist of hardware and software.

Computer Basics 1/6/16. Computer Organization. Computer systems consist of hardware and software. Hardware and Software Computer Basics TOPICS Computer Organization Data Representation Program Execution Computer Languages Computer systems consist of hardware and software. Hardware includes the tangible

More information

CS 113: Introduction to

CS 113: Introduction to CS 113: Introduction to Course information MWF 12:20-1:10pm 1/21-2/15, 306 Hollister Hall Add/drop deadline: 1/28 C Instructor: David Crandall See website for office hours and contact information Prerequisites

More information

Administration Computers Software Algorithms Programming Languages

Administration Computers Software Algorithms Programming Languages Administration Computers Software Algorithms Programming Languages http://www.cs.sfu.ca/cc/130/johnwill/ This course does not use Canvas John Edgar 3 Come to class Read ahead Attend the labs You get practice

More information

CHAPTER 1 Introduction to Computers and Java

CHAPTER 1 Introduction to Computers and Java CHAPTER 1 Introduction to Computers and Java Copyright 2016 Pearson Education, Inc., Hoboken NJ Chapter Topics Chapter 1 discusses the following main topics: Why Program? Computer Systems: Hardware and

More information

CONTENTS: What Is Programming? How a Computer Works Programming Languages Java Basics. COMP-202 Unit 1: Introduction

CONTENTS: What Is Programming? How a Computer Works Programming Languages Java Basics. COMP-202 Unit 1: Introduction CONTENTS: What Is Programming? How a Computer Works Programming Languages Java Basics COMP-202 Unit 1: Introduction Announcements Did you miss the first lecture? Come talk to me after class. If you want

More information

COSC 123 Computer Creativity. Introduction to Java. Dr. Ramon Lawrence University of British Columbia Okanagan

COSC 123 Computer Creativity. Introduction to Java. Dr. Ramon Lawrence University of British Columbia Okanagan COSC 123 Computer Creativity Introduction to Java Dr. Ramon Lawrence University of British Columbia Okanagan ramon.lawrence@ubc.ca Key Points 1) Introduce Java, a general-purpose programming language,

More information

The return Statement

The return Statement The return Statement The return statement is the end point of the method. A callee is a method invoked by a caller. The callee returns to the caller if the callee completes all the statements (w/o a return

More information

Python for Analytics. Python Fundamentals RSI Chapters 1 and 2

Python for Analytics. Python Fundamentals RSI Chapters 1 and 2 Python for Analytics Python Fundamentals RSI Chapters 1 and 2 Learning Objectives Theory: You should be able to explain... General programming terms like source code, interpreter, compiler, object code,

More information

Outline. CIS 110: Introduction to Computer Programming. What is Computer Science? What is computer programming? What is computer science?

Outline. CIS 110: Introduction to Computer Programming. What is Computer Science? What is computer programming? What is computer science? Outline CIS 110: Introduction to Computer Programming Lecture 1 An introduction of an introduction ( 1.1 1.3)* 1. What is computer science and computer programming? 2. Introductions and logistics 3. The

More information

Maciej Sobieraj. Lecture 1

Maciej Sobieraj. Lecture 1 Maciej Sobieraj Lecture 1 Outline 1. Introduction to computer programming 2. Advanced flow control and data aggregates Your first program First we need to define our expectations for the program. They

More information

Algorithms and Programming I. Lecture#12 Spring 2015

Algorithms and Programming I. Lecture#12 Spring 2015 Algorithms and Programming I Lecture#12 Spring 2015 Think Python How to Think Like a Computer Scientist By :Allen Downey Installing Python Follow the instructions on installing Python and IDLE on your

More information

Computer Basics 1/24/13. Computer Organization. Computer systems consist of hardware and software.

Computer Basics 1/24/13. Computer Organization. Computer systems consist of hardware and software. Hardware and Software Computer Basics TOPICS Computer Organization Data Representation Program Execution Computer Languages Computer systems consist of hardware and software. Hardware includes the tangible

More information

Introduction to computers and Python. Matthieu Choplin

Introduction to computers and Python. Matthieu Choplin Introduction to computers and Python Matthieu Choplin matthieu.choplin@city.ac.uk http://moodle.city.ac.uk/ 1 Objectives To get a brief overview of what Python is To understand computer basics and programs

More information

(Refer Slide Time: 1:27)

(Refer Slide Time: 1:27) Data Structures and Algorithms Dr. Naveen Garg Department of Computer Science and Engineering Indian Institute of Technology, Delhi Lecture 1 Introduction to Data Structures and Algorithms Welcome to data

More information

CS102 Unit 2. Sets and Mathematical Formalism Programming Languages and Simple Program Execution

CS102 Unit 2. Sets and Mathematical Formalism Programming Languages and Simple Program Execution 1 CS102 Unit 2 Sets and Mathematical Formalism Programming Languages and Simple Program Execution 2 Review Show how "Hi!\n" would be stored in the memory below Use decimal to represent each byte Remember

More information

Monty Python and the Holy Grail (1975) BBM 101. Introduction to Programming I. Lecture #03 Introduction to Python and Programming, Control Flow

Monty Python and the Holy Grail (1975) BBM 101. Introduction to Programming I. Lecture #03 Introduction to Python and Programming, Control Flow BBM 101 Monty Python and the Holy Grail (1975) Introduction to Programming I Lecture #03 Introduction to Python and Programming, Control Flow Aykut Erdem, Fuat Akal & Aydın Kaya // Fall 2018 Last time

More information

CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch

CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch CSCI 1100L: Topics in Computing Lab Lab 11: Programming with Scratch Purpose: We will take a look at programming this week using a language called Scratch. Scratch is a programming language that was developed

More information

Computer Components. Software{ User Programs. Operating System. Hardware

Computer Components. Software{ User Programs. Operating System. Hardware Computer Components Software{ User Programs Operating System Hardware What are Programs? Programs provide instructions for computers Similar to giving directions to a person who is trying to get from point

More information

LCC 6310 The Computer as an Expressive Medium. Lecture 1

LCC 6310 The Computer as an Expressive Medium. Lecture 1 LCC 6310 The Computer as an Expressive Medium Lecture 1 Overview Go over the syllabus Brief introduction to me and my work Art, programming and Java Signup sheet Syllabus If you re not listed, please add

More information

Introduction to Programming: Variables and Objects. HORT Lecture 7 Instructor: Kranthi Varala

Introduction to Programming: Variables and Objects. HORT Lecture 7 Instructor: Kranthi Varala Introduction to Programming: Variables and Objects HORT 59000 Lecture 7 Instructor: Kranthi Varala What is a program? A set of instructions to the computer that perform a specified task in a specified

More information

CompSci 125 Lecture 02

CompSci 125 Lecture 02 Assignments CompSci 125 Lecture 02 Java and Java Programming with Eclipse! Homework:! http://coen.boisestate.edu/jconrad/compsci-125-homework! hw1 due Jan 28 (MW), 29 (TuTh)! Programming:! http://coen.boisestate.edu/jconrad/cs125-programming-assignments!

More information

Computer Principles and Components 1

Computer Principles and Components 1 Computer Principles and Components 1 Course Map This module provides an overview of the hardware and software environment being used throughout the course. Introduction Computer Principles and Components

More information

Features of C. Portable Procedural / Modular Structured Language Statically typed Middle level language

Features of C. Portable Procedural / Modular Structured Language Statically typed Middle level language 1 History C is a general-purpose, high-level language that was originally developed by Dennis M. Ritchie to develop the UNIX operating system at Bell Labs. C was originally first implemented on the DEC

More information

COMP-202: Foundations of Programming. Lecture 2: Variables, and Data Types Sandeep Manjanna, Summer 2015

COMP-202: Foundations of Programming. Lecture 2: Variables, and Data Types Sandeep Manjanna, Summer 2015 COMP-202: Foundations of Programming Lecture 2: Variables, and Data Types Sandeep Manjanna, Summer 2015 Announcements Midterm Exams on 4 th of June (12:35 14:35) Room allocation will be announced soon

More information

Familiarity with data types, data structures, as well as standard program design, development, and debugging techniques.

Familiarity with data types, data structures, as well as standard program design, development, and debugging techniques. EE 472 Lab 1 (Individual) Introduction to C and the Lab Environment University of Washington - Department of Electrical Engineering Introduction: This lab has two main purposes. The first is to introduce

More information

MATLAB The first steps. Edited by Péter Vass

MATLAB The first steps. Edited by Péter Vass MATLAB The first steps Edited by Péter Vass MATLAB The name MATLAB is derived from the expression MATrix LABoratory. It is used for the identification of a software and a programming language. As a software,

More information

CSI32 Object-Oriented Programming

CSI32 Object-Oriented Programming Outline Department of Mathematics and Computer Science Bronx Community College February 2, 2015 Outline Outline 1 Chapter 1 Cornerstones of Computing Textbook Object-Oriented Programming in Python Goldwasser

More information

BIL 104E Introduction to Scientific and Engineering Computing. Lecture 1

BIL 104E Introduction to Scientific and Engineering Computing. Lecture 1 BIL 104E Introduction to Scientific and Engineering Computing Lecture 1 Introduction As engineers and scientists why do we need computers? We use computers to solve a variety of problems ranging from evaluation

More information

Introduction to Computers and Java

Introduction to Computers and Java Introduction to Computers and Java Chapter 1 Chapter 1 1 Objectives overview computer hardware and software introduce program design and object-oriented programming overview the Java programming language

More information

Chapter 2. Designing a Program. Input, Processing, and Output Fall 2016, CSUS. Chapter 2.1

Chapter 2. Designing a Program. Input, Processing, and Output Fall 2016, CSUS. Chapter 2.1 Chapter 2 Input, Processing, and Output Fall 2016, CSUS Designing a Program Chapter 2.1 1 Algorithms They are the logic on how to do something how to compute the value of Pi how to delete a file how to

More information

Chapter 1. Introduction to Computers and Programming. M hiwa ahmad aziz

Chapter 1. Introduction to Computers and Programming.   M hiwa ahmad aziz . Chapter 1 Introduction to Computers and Programming www.raparinweb.com M hiwa ahmad aziz 1 Ch 1 - Introduction to Computers and Programming Hardware Terminology Main Memory Auxiliary Memory Drives Writing

More information

CSI31 Introduction to Computer Programming I. Dr. Sharon Persinger Fall

CSI31 Introduction to Computer Programming I. Dr. Sharon Persinger Fall CSI31 Introduction to Computer Programming I Dr. Sharon Persinger Fall 2018 1 Overview Basic definitions: Computer Computer science Algorithm Programming language What is a computer? A modern computer

More information

Our Strategy for Learning Fortran 90

Our Strategy for Learning Fortran 90 Our Strategy for Learning Fortran 90 We want to consider some computational problems which build in complexity. evaluating an integral solving nonlinear equations vector/matrix operations fitting data

More information

Exercise. Write a program which allows the user to enter the math grades one by one (-1 to exit), and outputs a histogram.

Exercise. Write a program which allows the user to enter the math grades one by one (-1 to exit), and outputs a histogram. Exercise Write a program which allows the user to enter the math grades one by one (-1 to exit), and outputs a histogram. Zheng-Liang Lu Java Programming 197 / 227 1... 2 int[] hist = new int[5]; 3 //

More information

Course Outline. Introduction to java

Course Outline. Introduction to java Course Outline 1. Introduction to OO programming 2. Language Basics Syntax and Semantics 3. Algorithms, stepwise refinements. 4. Quiz/Assignment ( 5. Repetitions (for loops) 6. Writing simple classes 7.

More information

More about Binary 9/6/2016

More about Binary 9/6/2016 More about Binary 9/6/2016 Unsigned vs. Two s Complement 8-bit example: 1 1 0 0 0 0 1 1 2 7 +2 6 + 2 1 +2 0 = 128+64+2+1 = 195-2 7 +2 6 + 2 1 +2 0 = -128+64+2+1 = -61 Why does two s complement work this

More information

Method Invocation. Zheng-Liang Lu Java Programming 189 / 226

Method Invocation. Zheng-Liang Lu Java Programming 189 / 226 Method Invocation Note that the input parameters are sort of variables declared within the method as placeholders. When calling the method, one needs to provide arguments, which must match the parameters

More information

CS 1713 Introduction to Computer Programming II Ch 0 Overview - Problem solving

CS 1713 Introduction to Computer Programming II Ch 0 Overview - Problem solving CS 1713 Introduction to Computer Programming II Ch 0 Overview - Problem solving Turgay Korkmaz Office: SB 4.01.13 Phone: (210) 458-7346 Fax: (210) 458-4437 e-mail: korkmaz@cs.utsa.edu web: www.cs.utsa.edu/~korkmaz

More information

Chapter 1: Introduction to Computers and Java

Chapter 1: Introduction to Computers and Java Chapter 1: Introduction to Computers and Java Starting Out with Java: From Control Structures through Objects Fifth Edition by Tony Gaddis Chapter Topics Chapter 1 discusses the following main topics:

More information

8/23/2014. Chapter Topics. Introduction. Java History. Why Program? Java Applications and Applets. Chapter 1: Introduction to Computers and Java

8/23/2014. Chapter Topics. Introduction. Java History. Why Program? Java Applications and Applets. Chapter 1: Introduction to Computers and Java Chapter 1: Introduction to Computers and Java Starting Out with Java: From Control Structures through Objects Fifth Edition by Tony Gaddis Chapter Topics Chapter 1 discusses the following main topics:

More information

assembler Machine Code Object Files linker Executable File

assembler Machine Code Object Files linker Executable File CSCE A211 Programming Intro What is a Programming Language Assemblers, Compilers, Interpreters A compiler translates programs in high level languages into machine language that can be executed by the computer.

More information

Limitations of Algorithmic Solvability In this Chapter we investigate the power of algorithms to solve problems Some can be solved algorithmically and

Limitations of Algorithmic Solvability In this Chapter we investigate the power of algorithms to solve problems Some can be solved algorithmically and Computer Language Theory Chapter 4: Decidability 1 Limitations of Algorithmic Solvability In this Chapter we investigate the power of algorithms to solve problems Some can be solved algorithmically and

More information

false, import, new 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4

false, import, new 1 class Lecture2 { 2 3 Data types, Variables, and Operators 4 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4 5 } 6 7 // Keywords: 8 byte, short, int, long, char, float, double, boolean, true, false, import, new Zheng-Liang Lu Java Programming 44

More information

Slide Set 2. for ENCM 335 in Fall Steve Norman, PhD, PEng

Slide Set 2. for ENCM 335 in Fall Steve Norman, PhD, PEng Slide Set 2 for ENCM 335 in Fall 2018 Steve Norman, PhD, PEng Electrical & Computer Engineering Schulich School of Engineering University of Calgary September 2018 ENCM 335 Fall 2018 Slide Set 2 slide

More information

CSC116: Introduction to Computing - Java

CSC116: Introduction to Computing - Java CSC116: Introduction to Computing - Java Course Information Introductions Website Syllabus Computers First Java Program Text Editor Helpful Commands Java Download Intro to CSC116 Instructors Course Instructor:

More information

ECON 502 INTRODUCTION TO MATLAB Nov 9, 2007 TA: Murat Koyuncu

ECON 502 INTRODUCTION TO MATLAB Nov 9, 2007 TA: Murat Koyuncu ECON 502 INTRODUCTION TO MATLAB Nov 9, 2007 TA: Murat Koyuncu 0. What is MATLAB? 1 MATLAB stands for matrix laboratory and is one of the most popular software for numerical computation. MATLAB s basic

More information

Terminology & Basic Concepts

Terminology & Basic Concepts Terminology & Basic Concepts Language Processors The basic model of a language processor is the black box translator (or transducer) Has one input stream, one output stream, and a black box (program) that

More information

Lecture 1: Hello, MATLAB!

Lecture 1: Hello, MATLAB! Lecture 1: Hello, MATLAB! Math 98, Spring 2018 Math 98, Spring 2018 Lecture 1: Hello, MATLAB! 1 / 21 Syllabus Instructor: Eric Hallman Class Website: https://math.berkeley.edu/~ehallman/98-fa18/ Login:!cmfmath98

More information

An Introduction to Python (TEJ3M & TEJ4M)

An Introduction to Python (TEJ3M & TEJ4M) An Introduction to Python (TEJ3M & TEJ4M) What is a Programming Language? A high-level language is a programming language that enables a programmer to write programs that are more or less independent of

More information

Full file at

Full file at Java Programming: From Problem Analysis to Program Design, 3 rd Edition 2-1 Chapter 2 Basic Elements of Java At a Glance Instructor s Manual Table of Contents Overview Objectives s Quick Quizzes Class

More information

SECTION 1: INTRODUCTION. ENGR 112 Introduction to Engineering Computing

SECTION 1: INTRODUCTION. ENGR 112 Introduction to Engineering Computing SECTION 1: INTRODUCTION ENGR 112 Introduction to Engineering Computing 2 Course Overview What is Programming? 3 Programming The implementation of algorithms in a particular computer programming language

More information

false, import, new 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4

false, import, new 1 class Lecture2 { 2 3 Data types, Variables, and Operators 4 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4 5 } 6 7 // Keywords: 8 byte, short, int, long, char, float, double, boolean, true, false, import, new Zheng-Liang Lu Java Programming 44

More information

Scientific Computing: Lecture 1

Scientific Computing: Lecture 1 Scientific Computing: Lecture 1 Introduction to course, syllabus, software Getting started Enthought Canopy, TextWrangler editor, python environment, ipython, unix shell Data structures in Python Integers,

More information

false, import, new 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4

false, import, new 1 class Lecture2 { 2 3 Data types, Variables, and Operators 4 1 class Lecture2 { 2 3 "Data types, Variables, and Operators" 4 5 } 6 7 // Keywords: 8 byte, short, int, long, char, float, double, boolean, true, false, import, new Zheng-Liang Lu Java Programming 44

More information

Topics. Hardware and Software. Introduction. Main Memory. The CPU 9/21/2014. Introduction to Computers and Programming

Topics. Hardware and Software. Introduction. Main Memory. The CPU 9/21/2014. Introduction to Computers and Programming Topics C H A P T E R 1 Introduction to Computers and Programming Introduction Hardware and Software How Computers Store Data Using Python Introduction Computers can be programmed Designed to do any job

More information

PROBLEM SOLVING AND PYTHON PROGRAMMING

PROBLEM SOLVING AND PYTHON PROGRAMMING ALGORITHM UNIT-1 It is defined as a sequence of instructions that describe a method for solving a problem. In other words it is a step by step procedure for solving a problem. Properties of Algorithms

More information

Programming Fundamentals (CS 302 ) Dr. Ihsan Ullah. Lecturer Department of Computer Science & IT University of Balochistan

Programming Fundamentals (CS 302 ) Dr. Ihsan Ullah. Lecturer Department of Computer Science & IT University of Balochistan Programming Fundamentals (CS 302 ) Dr. Ihsan Ullah Lecturer Department of Computer Science & IT University of Balochistan 1 Outline p Introduction p Program development p C language and beginning with

More information

CSc 10200! Introduction to Computing. Lecture 1 Edgardo Molina Fall 2013 City College of New York

CSc 10200! Introduction to Computing. Lecture 1 Edgardo Molina Fall 2013 City College of New York CSc 10200! Introduction to Computing Lecture 1 Edgardo Molina Fall 2013 City College of New York 1 Introduction to Computing Lectures: Tuesday and Thursday s (2-2:50 pm) Location: NAC 1/202 Recitation:

More information

REVIEW. The C++ Programming Language. CS 151 Review #2

REVIEW. The C++ Programming Language. CS 151 Review #2 REVIEW The C++ Programming Language Computer programming courses generally concentrate on program design that can be applied to any number of programming languages on the market. It is imperative, however,

More information

Computer Science 2500 Computer Organization Rensselaer Polytechnic Institute Spring Topic Notes: C and Unix Overview

Computer Science 2500 Computer Organization Rensselaer Polytechnic Institute Spring Topic Notes: C and Unix Overview Computer Science 2500 Computer Organization Rensselaer Polytechnic Institute Spring 2009 Topic Notes: C and Unix Overview This course is about computer organization, but since most of our programming is

More information

Chapter 1 Introduction to MATLAB

Chapter 1 Introduction to MATLAB EGR115 Introduction to Computing for Engineers Introduction to MATLAB from: S.J. Chapman, MATLAB Programming for Engineers, 5 th Ed. 2016 Cengage Learning Topics Introduction: Computing for Engineers 1.1

More information

Midterm CSE 21 Fall 2012

Midterm CSE 21 Fall 2012 Signature Name Student ID Midterm CSE 21 Fall 2012 Page 1 Page 2 Page 3 Page 4 Page 5 Page 6 _ (20 points) _ (15 points) _ (21 points) _ (13 points) _ (9 points) _ (7 points) Total _ (85 points) (80 points

More information

CPS104 Computer Organization Lecture 1. CPS104: Computer Organization. Meat of the Course. Robert Wagner

CPS104 Computer Organization Lecture 1. CPS104: Computer Organization. Meat of the Course. Robert Wagner CPS104 Computer Organization Lecture 1 Robert Wagner Slides available on: http://www.cs.duke.edu/~raw/cps104/lectures 1 CPS104: Computer Organization Instructor: Robert Wagner Office: LSRC D336, 660-6536

More information

Eclipse Environment Setup

Eclipse Environment Setup Eclipse Environment Setup Adapted from a document from Jeffrey Miller and the CS201 team by Shiyuan Sheng. Introduction This lab document will go over the steps to install and set up Eclipse, which is

More information

CSCE 120: Learning To Code

CSCE 120: Learning To Code CSCE 120: Learning To Code Manipulating Data I Introduction This module is designed to get you started working with data by understanding and using variables and data types in JavaScript. It will also

More information

ELEMENTARY MATLAB PROGRAMMING

ELEMENTARY MATLAB PROGRAMMING 1 ELEMENTARY MATLAB PROGRAMMING (Version R2013a used here so some differences may be encountered) COPYRIGHT Irving K. Robbins 1992, 1998, 2014, 2015 All rights reserved INTRODUCTION % It is assumed the

More information

Principles of computer programming. Profesor : doc. dr Marko Tanasković Assistent : doc. dr Marko Tanasković

Principles of computer programming. Profesor : doc. dr Marko Tanasković Assistent : doc. dr Marko Tanasković Principles of computer programming Profesor : doc. dr Marko Tanasković Assistent : doc. dr Marko Tanasković E-mail: mtanaskovic@singidunum.ac.rs Course organization Lectures: Presentation of concepts and

More information

Software Lesson 2 Outline

Software Lesson 2 Outline Software Lesson 2 Outline 1. Software Lesson 2 Outline 2. Languages 3. Ingredients of a Language 4. Kinds of Languages 5. Natural Languages #1 6. Natural Languages #2 7. Natural Languages #3 8. Natural

More information

CPS122 Lecture: From Python to Java

CPS122 Lecture: From Python to Java Objectives: CPS122 Lecture: From Python to Java last revised January 7, 2013 1. To introduce the notion of a compiled language 2. To introduce the notions of data type and a statically typed language 3.

More information

Act like a code monkey Coding Basics

Act like a code monkey Coding Basics Act like a code monkey Coding Basics Announcement Homework 1 grade is posted If you believe there is an error in grading (assignments or quizzes), you may request a regrading within one week of receiving

More information

CSC116: Introduction to Computing - Java

CSC116: Introduction to Computing - Java CSC116: Introduction to Computing - Java Intro to CSC116 Course Information Introductions Website Syllabus Computers First Java Program Text Editor Helpful Commands Java Download Course Instructor: Instructors

More information