INTRODUCTION Introduction to Computer Science I - COMP 1005, 1405 Instructor : Behnam Hajian

Slides:



Advertisements
Similar presentations
Introduction to Computer Programming Nai-Wei Lin Department of Computer Science and Information Engineering National Chung Cheng University.
Advertisements

ICS103 Programming in C Lecture 1: Overview of Computers & Programming
Lecture 1: Overview of Computers & Programming
COSC 120 Computer Programming
Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Starting Out with Programming Logic & Design First Edition by Tony Gaddis.
1 Engineering Problem Solving With C++ An Object Based Approach Fundamental Concepts Chapter 1 Engineering Problem Solving.
Introduction to Computer Systems
©TheMcGraw-Hill Companies, Inc. Permission required for reproduction or display. COMPSCI 125 Introduction to Computer Science I.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
©TheMcGraw-Hill Companies, Inc. Permission required for reproduction or display. COMPSCI 125 Introduction to Computer Science I.
Introduction to C++ Programming CS 117 Section 2 and KNET Sections Spring 2001 MWF 1:40-2:30.
1 Introduction to computers Overview l · Grading Policy »Cheating Rules (serious concern) »Examinations and Fixation of Timings »Quizzes »Homework Assignments.
Starting Out with C++: Early Objects 5/e © 2006 Pearson Education. All Rights Reserved Starting Out with C++: Early Objects 5 th Edition Chapter 1 Introduction.
CIS 260 Computer Programming I in C Prof. Timothy Arndt.
CS190/295 Programming in Python for Life Sciences: Lecture 1 Instructor: Xiaohui Xie University of California, Irvine.
Microsoft Visual Basic 2012 CHAPTER ONE Introduction to Visual Basic 2012 Programming.
Microsoft Visual Basic 2005 CHAPTER 1 Introduction to Visual Basic 2005 Programming.
CS102 Introduction to Computer Programming
Introduction to Computers and Python. What is a Computer? Computer- a device capable of performing computations and making logical decisions at speeds.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Alternate Version of STARTING OUT WITH C++ 4 th Edition Chapter 1 Introduction to Computers and Programming.
Why Program? Computer – programmable machine designed to follow instructions Program – instructions in computer memory to make it do something Programmer.
Chapter Introduction to Computers and Programming 1.
INTRODUCTION Introduction to Systems Programming - COMP 1002, 1402 Instructor : Behnam Hajian
Department of Computer and Information Science, School of Science, IUPUI Dale Roberts, Lecturer Computer Science, IUPUI CSCI.
CSC 125 Introduction to C++ Programming Chapter 1 Introduction to Computers and Programming.
Introduction COMP104: Fundamentals and Methodology.
Elements of a Computer System Dr Kathryn Merrick Thursday 4 th June, 2009.
CSE 1340 Introduction to Computing Concepts Class 2.
INTRODUCTION TO COMPUTER PROGRAMMING itc-314 LECTURE 01.
INTRODUCTION TO COMPUTING
1 TOPIC 1 INTRODUCTION TO COMPUTER SCIENCE AND PROGRAMMING Topic 1 Introduction to Computer Science and Programming Notes adapted from Introduction to.
COMPUTER SYSTEM.
COP1220/CGS2423 Introduction to C++/ C for Engineers Professor: Dr. Miguel Alonso Jr. Fall 2008.
Copyright © 2012 Pearson Education, Inc. Chapter 1: Introduction to Computers and Programming.
Chapter 1: Introduction to Computers and Programming.
Copyright © 2009 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 1: Introduction to Computers and Programming.
Unit - 1 Basic Computer Architecture P. Sugin Benzigar.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Starting Out with C++ Early Objects Seventh Edition by Tony Gaddis, Judy.
COMP1050 Winter 2015 Computer System Maintenance.
© Copyright 1992–2004 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. 1 Introduction to Computers Outline 1.1Introduction.
1 CISC181 Introduction to Computer Science Dr. McCoy Lecture 1 February 8, 2005.
Module 2 : Part 1 INTRODUCTION TO HARDWARE & SOFTWARE INTRODUCTION TO HARDWARE & SOFTWARE.
COMPUTER PROGRAMMING. Computer programming the objective of the module to gain the necessary skills to develop a computer program using one of the high.
Computer Organization & Assembly Language © by DR. M. Amer.
CS 127 Introduction to Computer Science. What is a computer?  “A machine that stores and manipulates information under the control of a changeable program”
Computing Systems & Programming ECE Fundamental Concepts Chapter 1 Engineering Problem Solving.
Beginning Snapshots Chapter 0. C++ An Introduction to Computing, 3rd ed. 2 Objectives Give an overview of computer science Show its breadth Provide context.
Copyright 2003 Scott/Jones Publishing Standard Version of Starting Out with C++, 4th Edition Chapter 1 Introduction to Computers and Programming.
Problem Solving Techniques Using Pascal Allen C.-H. Wu Department of Computer Science Tsing Hua University Hsinchu, Taiwan 30043, ROC
Course Title: Introduction to Computer Course Instructor: ILTAF MEHDI Chapter No: 04 1BY ILTAF MEHDI (MCS, MCSE, CCNA)
UniMAP Sem2-10/11 DKT121: Fundamental of Computer Programming1 Introduction to C – Part 1.
Brief Version of Starting Out with C++ Chapter 1 Introduction to Computers and Programming.
CHAPTER 1.1 INTRODUCTION TO COMPUTERS AND C++ Dr. Shady Yehia Elmashad.
Chapter 11  Getting ready to program  Hardware Model  Software Model  Programming Languages  Facts about C++  Program Development Process  The Hello-world.
Copyright © 2014, 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Starting Out with C++ Early Objects Eighth Edition by Tony Gaddis,
Chapter 1: Introduction to Computers and Programming.
Copyright © 2010 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 1: Introduction to Computers and Programming.
Victoria Ibarra Mat:  Generally, Computer hardware is divided into four main functional areas. These are:  Input devices Input devices  Output.
Chapter 1: Introduction to Computers and Programming
Java Programming: From the Ground Up
Computer Fundamentals 1
Introduction to Visual Basic 2008 Programming
GC101 Introduction to computers and programs
ICS103 Programming in C Lecture 1: Overview of Computers & Programming
Java programming lecture one
Programming COMP104: Fundamentals and Methodology Introduction.
CS190/295 Programming in Python for Life Sciences: Lecture 1
National Diploma in Computer Studies
Chapter 1: Introduction to Computers and Programming
Presentation transcript:

INTRODUCTION Introduction to Computer Science I - COMP 1005, 1405 Instructor : Behnam Hajian

 Attention:  A large amount of material in this set of slides has gotten from course notes prepared by Dr. Mark Lanthier.

Objectives and syllabus The objectives in this course is  To indentify the basic view of architecture of a computer.  To expose students to a high level programming language (i.e., java).  To make students learn the basic programming concepts.

Where are you? Where you are? What you learn?

Objectives and syllabus  An introduction to Computer Science and Problem Solving.  Variables and Object.  Data Structure.  Control statements (if-else, switch-case).  Loops (while, for).  2D graphics.  Array, and list.  Methods and Functions.  Calculations, Formatting and Conversions.  Sorting.  Recursion.  Shared data

Evaluation, Course information: Evaluation:  6 programming assignments:30%  3 Quizzes (in-class exams):30%  Tutorials participation 10%  Final Exam: 30% Website:  Course material will be available on WebCT or the course link in my webpage.  OR Lectures:  Monday&Wednesday 14:35 PM – 15: Steacie Building (SC).

Course information Office hours:  Monday & Wednesday 4PM - 5 HP 5331 TextBook:  Course notes of Introduction to Computer Science 1 mainained by Mark Lantier uploaded in WebCT. References:  Getting Started with Processing, Casey Reas and Ben Fry 

Computers  What is a computer?  A computational device  Logical decisions billions of times faster than humans  Hardware keyboard, screen, disks, memory, CPU  Software , word processing, spreadsheets, OS

What are Computers Used For?  Communications: Internet, , cell phones  Word Processing: typing/printing documents  Business Applications: accounting, spreadsheets  Engineering Applications: scientific analysis, simulations  Database Management: police records, stock market  Entertainment: games, multimedia applications  Manufacturing: CAD/CAM, robotics, assembly ... many more...

Who is Involved With Computers ?  System/Hardware Designers = people that design computers and related products.  Manufacturers = people that actually build and assemble computers.  Software Designers = people that design applications to be used with the computers.  Programmers = people that write computer programs to achieve working applications, games and other software packages.  End User = people that buy and use the software when it is done.  We are going to play the role of the Programmer in this course.

Computer Organization  Input unit  keyboard, microphone  Output unit  screen, printer  Memory unit  Random Access Memory (RAM) short-term, rapid access, low capacity warehouse  Read only memory ROM Smaller amount of memory stable when power off. Stores enough code to boot system

Computer Organization  Secondary storage unit  disks, tapes long-term, slow access, high capacity warehouse  Central Processing Unit (CPU): Microprocessor (Intel Pentium, Motorola power PC): fetches machine instructions from memory, executes them  Arithmetic and logic unit (ALU) calculations, comparisons  CU (Control Unit) coordinator, administrator,

Computer Architecture CPU Program Control Unit ALU MemoryI/O

What is a program ? A program is traditionally known as:  a sequence of instructions that can be executed by a computer to solve some problem.  In this course, we will learn to write our own programs to solve some very simple problems.

How do we write good programs ?

What is a programming language ?

What is Procedural programming ?

What is Object-Oriented programming ?

Processing

sketch  Each program is called a “sketch” in Processing. The top left play button starts your program which brings up a window (shown yellow here with a picture of a teddy bear). Since, many processing programs are meant to be animations, there is also a stop button beside the play button to stop the program. You should explore the Processing IDE (i.e., Integrated Development Environment) a little to get used to it. syntax JAVA  Processing uses the same syntax as JAVA. That means, Processing code looks almost exactly like JAVA code. So when you are programming in Processing, you are actually learning JAVA as well. However, Processing has been designed in a way that makes it easier to get you started because some of the overhead in getting your first program working is hidden.  As you may recall, Processing is a graphics-based language and therefore we will spend a lot of time and effort drawing various things on the screen. When drawing anything, it is important to specify where you want to draw.

The JAVA Programming Language JAVA is a very popular object-oriented programming language from SUN Microsystems. It has become a basis for new technologies such as: Enterprise Java Beans (EJB’s), Servlets and Java Server Pages (JSPs), etc. In addition, many packages have been added which extend the language to provide special features:  Java Media Framework (for video streaming, webcams, MP3 files, etc)  Java 3D (for 3D graphics)  J2ME (for wireless communications such as cell phones, PDAs)

Why java?

Writing a program in Processing  Use Java syntax.  In order to tell computer what to do, we have to use Instructions. They are called statements.  Each statement follow a specific syntax.  Each statement end with Semicolons ;  Compiling is the process of converting a program into instructions that can  be understood by the computer.

 As you may recall, Processing is a graphics-based language and therefore we will spend a lot of time and effort drawing various things on the screen. When drawing anything, it is important to specify where you want to draw.

Colors in Processing

More graphical functions

Some important comments on java  Java is a case sensitive language.  Most of the library names start with capital letters.  In order to complete your code in netbeans you can use control + space keys.

Problem Solving

Understand the Problem

Formulation of Problem

Example

Develop and Algorithm

Write the program

Test the Program

Solution evaluation

Abstraction  Abstraction  Abstraction is the process of reducing or factoring out details that are not necessary in order to describe an algorithm

Algorithm efficiency  Algorithm efficiency is used to describe properties of an algorithm relating to how much of various types of resources it consumes. (Wikipedia)

Difference between print and println  The first line uses print while the second line uses println. When using just print, the next text to be printed will be immediately to the right of this text.  When using println, a line feed and carriage return is printed, which means that the text to follow will appear at the beginning of the next line of the console (i.e., output window).

Example:

QUESTIONS?