CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday –...
-
date post
21-Dec-2015 -
Category
Documents
-
view
220 -
download
1
Transcript of CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday –...
![Page 1: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/1.jpg)
CS101- Lecture 1 1
CS101 Fall 2004 Course Introduction• Professor Douglas Moody
– Monday – 12:00-1:40– Email – [email protected]– Web Site: websupport1.citytech.cuny.edu
Click on Technology and Design
• Select My page
– Office Hours Monday: 6-7 pm
Friday: 5-6 pm and by appointment
• Prerequisite: Enthusiasm about computers
![Page 2: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/2.jpg)
CS101- Lecture 1 2
CS101 Fall 2004
• Text Book– Programming Right from the Start with Visual
Basic.Net Updated, Edition by Crews-MurphyMillspaugh, Prentice-Hall Publishers
• Attendance : Mandatory , maximum of 10% absence
![Page 3: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/3.jpg)
CS101- Lecture 1 3
CS101 Fall 2004• Grading
– Tests (19%)– Midterm (19%)– Final (31%)– Programs (31%) (Homework Assignments)
• Programs / Homeworks must done in order to succeed in the course
• Plan on 1 and ½ hours of non class time for the course
![Page 4: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/4.jpg)
CS101- Lecture 1 4
CS101 Fall 2004 Objectives
• Learn how computer solve problems and perform tasks
• Understand the concepts behind computer programs
• Develop some basic programming skills
• Have fun making the computer work for you
![Page 5: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/5.jpg)
CS101- Lecture 1 5
1-1 Logic and Syntax
• A computer program is a solution to a problem.
• An algorithm is the logical design used to accomplish a specific objective.
• The Visual Logic Development System combines the utility of flowcharts and pseudocode with computer simulation.
![Page 6: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/6.jpg)
CS101- Lecture 1 6
1-1 Logic and Syntax (cont.)
• Syntax refers to the specific rules of a programming language.
• An information system is a combination of people and technology that collect, organize, and process data to produce information.
![Page 7: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/7.jpg)
CS101- Lecture 1 7
1-1 Logic and Syntax (cont.)
• An information system must do at least three things:– input data into the system– process data within the system– output resulting information from the system
![Page 8: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/8.jpg)
CS101- Lecture 1 8
1-2 “Hello World”
![Page 9: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/9.jpg)
CS101- Lecture 1 9
1-2 “Hello World” (cont.)
![Page 10: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/10.jpg)
CS101- Lecture 1 10
1-2 “Hello World” (cont.)
![Page 11: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/11.jpg)
CS101- Lecture 1 11
1-3 Input Statements
• An input statement accepts data from the user and stores that data into a variable.
• A variable is a storage location that can be accessed and changed by developer code.
![Page 12: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/12.jpg)
CS101- Lecture 1 12
1-3 Input Statements (cont.)
![Page 13: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/13.jpg)
CS101- Lecture 1 13
1-3 Input Statements (cont.)
![Page 14: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/14.jpg)
CS101- Lecture 1 14
Simple Programming Formats
![Page 15: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/15.jpg)
CS101- Lecture 1 15
1-4 Weekly Paycheck Program
The weekly paycheck program has two input variables:
Hours and Rate
![Page 16: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/16.jpg)
CS101- Lecture 1 16
1-5 Assignment Statements
• The assignment statement can be used to perform a calculation and store the result.
• An expression is a value-returning code element, such as a variable or mathematical formula.
![Page 17: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/17.jpg)
CS101- Lecture 1 17
How to WriteArithmetic Expressions
![Page 18: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/18.jpg)
CS101- Lecture 1 18
How to WriteArithmetic Expressions (cont.)
![Page 19: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/19.jpg)
CS101- Lecture 1 19
1-6 Output Statements
• Types of output include– Screen output– Printed output– Sound output– Saving to storage devices
![Page 20: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/20.jpg)
CS101- Lecture 1 20
1-6 Output Statements (cont.)
![Page 21: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/21.jpg)
CS101- Lecture 1 21
1-6 Output Statements (cont.)
![Page 22: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/22.jpg)
CS101- Lecture 1 22
Intrinsic Functions
• Intrinsic functions are predefined commands that provide developers with common, helpful functionality.
![Page 23: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/23.jpg)
CS101- Lecture 1 23
Intrinsic Functions (cont.)
![Page 24: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/24.jpg)
CS101- Lecture 1 24
1-7 Debugging withVisual Logic
• A programming mistake is often called a bug.
![Page 25: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/25.jpg)
CS101- Lecture 1 25
Chapter Summary
• Variables are storage locations used for holding input and processing information.
• Each variable has two components: its name and its value.
• Input statements are used to get data into variables.
• Expressions are value-returning code elements.
![Page 26: CS101- Lecture 11 CS101 Fall 2004 Course Introduction Professor Douglas Moody –Monday – 12:00-1:40 –Email – dmoody@citytech.cuny.edu –Web Site: websupport1.citytech.cuny.edu.](https://reader035.fdocuments.net/reader035/viewer/2022081519/56649d565503460f94a3426b/html5/thumbnails/26.jpg)
CS101- Lecture 1 26
Chapter Summary (cont.)
• Assignment statements are used to perform calculations and store the result.
• Output statements are used to display information.
• Input, assignment, and output statements are sufficient to write small programs.