James Tam Introduction to CPSC 233 CPSC 233: Introduction to Computers II Object-oriented programming The "nuts and bolts" of programming Object-oriented.

Slides:



Advertisements
Similar presentations
Introduction To Java Objectives For Today â Introduction To Java â The Java Platform & The (JVM) Java Virtual Machine â Core Java (API) Application Programming.
Advertisements

Object Oriented Programming in Java George Mason University Fall 2011
James Tam Introduction To CPSC 233 James Tam Java Object-Orientation Event driven software.
James Tam Introduction To Java Programming You will learn about the process of creating Java programs and constructs for input, output, branching, looping,
James Tam Introduction To CPSC 231 And Computer Science James Tam.
James Tam CPSC 233: Introduction to Computers II Object-oriented programming Object-oriented design And a whole lot ole fun (you’ll have a …)
CPSC150 Fall 2008 Dr. L. Lambert. CPSC150 Overview Syllabus Use Textbook, ask questions, extra thorough, I will post sections covered All information.
Client Side Programming Using Java Applet Outcomes: You will be expected to know: – Java Applets and HTML file; –bytecode and platform independent programs;
James Tam Introduction To CPSC 231 James Tam Administrative (James Tam) Contact Information -Office: ICT 707 -
James Tam Introduction To CPSC 219 James Tam Administrative (James Tam) Contact Information -Office: ICT 707 -
1 Fall 2008ACS-1903 Chapter 1 Topics Java History Java Programs Why Program? Computer Systems: Hardware and Software Programming Languages What Is a Program.
James Tam Introduction To CPSC 231 And To Computer Science James Tam.
James Tam Introduction To Java Programming You will study the process of creating Java programs and constructs for input, output, branching, looping,
James Tam Introduction To CPSC 203 James Tam Administrative (James Tam) Contact Information -Office: ICT 707 -
James Tam Introduction To CPSC 203 James Tam Administrative (James Tam) Contact Information -Office: ICT 707 -
James Tam Introduction To CPSC 231 And Computer Science James Tam.
James Tam Introduction To CPSC 203 James Tam Administrative (James Tam) Contact Information -Office: ICT 707 -
James Tam CPSC 233: Introduction to Computers II Object-oriented programming Object-oriented design And a whole lot ole fun (you’ll have a …)
James Tam Creating Actual Computer Programs This section of notes describes how a computer program written by a person is translated to a form that can.
CSE 1301 J Lecture 2 Intro to Java Programming Richard Gesick.
01 Introduction to Java Technology. 2 Contents History of Java What is Java? Java Platforms Java Virtual Machine (JVM) Java Development Kit (JDK) Benefits.
LESSON 1 INTRODUCTION Compiled By: Edwin O. Okech [Tutor, Amoud University] JAVA PROGRAMMING.
CMSC 202 Computer Science II for Majors Fall 2009 Introduction.
Sadegh Aliakbary Sharif University of Technology Fall 2011.
BASIC JAVA PROGRAMMING TUTORIAL. History  James Gosling and Sun Microsystems  Oak  Java, May 20, 1995, Sun World  Hot Java –The first Java-enabled.
CSC 142 A 1 CSC 142 Introduction to Java [Reading: chapter 0]
Sadegh Aliakbary Sharif University of Technology Spring 2011.
Sadegh Aliakbary Sharif University of Technology Fall 2010.
CMSC 202 Computer Science II for Majors Object-Oriented Programming.
How to be an online student. How does it work? An online course follows a schedule and syllabus with due dates for assignments (just like an on-campus.
James Tam CPSC 203: Introduction To Computers (Independent Study) James Tam.
James Tam Introduction to CPSC 203 James Tam Administrative Contact Information Office: ICT 707 Phone:
Introduction to Computers and Java Chapter 1.3. A Sip of Java: Outline History of the Java Language Applets A First Java Program Compiling a Java Program.
Sadegh Aliakbary Sharif University of Technology Fall 2012.
James Tam Introduction To CPSC 203: Doha James Tam.
JAVA Java is a programming language and computing platform first released by Sun Microsystems in It was first developed by James Gosling at Sun Microsystems,
© 2012 Pearson Education, Inc. All rights reserved. 1-1 Why Java? Needed program portability – Program written in a language that would run on various.
Java means Coffee Java Coffee Beans The name “JAVA” was taken from a cup of coffee.
CS 3131 Introduction to Programming in Java Rich Maclin Computer Science Department.
Selected Topics in Information Technology Programming Language - JAVA Semester 1/2554.
Chapter 1 Section 1.1 Introduction to Java Slides prepared by Rose Williams, Binghamton University Kenrick Mock, University of Alaska Anchorage.
CSE S. Tanimoto Java Introduction 1 Java A Programming Language for Web-based Computing with Graphics.
CSE S. Tanimoto Java Introduction 1 Java A Programming Language for Web-based Computing with Graphics.
J ava P rogramming: From Problem Analysis to Program Design, From Problem Analysis to Program Design, Second Edition Second Edition D.S. Malik D.S. Malik.
Chapter 1: Introducing JAVA. 2 Introduction Why JAVA Applets and web applications Very rich GUI libraries Portability (machine independence) A real Object.
CSCI 330 UNIX and Network Programming Unit I Introduction.
1 The JAVA Language Object Oriented Technology Mithani Binjan M.
© 2012 Pearson Education, Inc. All rights reserved types of Java programs Application – Stand-alone program (run without a web browser) – Relaxed.
Today… “Hello World” ritual. Brief History of Java & How Java Works. Introduction to Java class structure. But first, next slide shows Java is No. 1 programming.
©2016 Pearson Education, Inc. Upper Saddle River, NJ. All Rights Reserved. CSC 110 – INTRO TO COMPUTING - PROGRAMMING Overview of Programming.
James Tam Introduction To CPSC 233 James Tam Java Object-Orientation Event driven software.
James Tam Introduction To Java Programming You will study the process of creating Java programs and constructs for input, output, branching, looping,
James Tam Introduction To CPSC 233 James Tam Java Object-Orientation Graphical-user interfaces.
ITP 109 Week 2 Trina Gregory Introduction to Java.
Java History Background information about Java and how the background affected it’s development.
James Tam Java History Background information about Java and how it affected it’s development.
Fundamental of Java Programming (630002) Unit – 1 Introduction to Java.
Introduction CMSC 202 Fall Instructors Mr. Ryan Bergeron – Lecture Section 01 Tues/Thu 1:00 – 2:15 am, Sondheim 111 – Lecture Section 04 Tues/Thu.
Lecture 1b- Introduction
JAVA, JAVA Applets, and JavaScript
Done By: Ashlee Lizarraga Ricky Usher Jacinto Roches Eli Gomez
Chapter No. : 1 Introduction to Java.
Java History Background information about Java and how the background affected it’s development 1.
Introduction to Java Dept. Business Computing University of Winnipeg
Advanced Programming Fall 2017.
Java History Background information about Java and how the background affected it’s development.
Introduction to Java Brief history of Java Sample Java Program
CSC 142 Introduction to Java [Reading: chapters 1 & 2]
Introduction To CPSC 233 James Tam Event driven software
Introduction To CPSC 233 James Tam Event driven software
Presentation transcript:

James Tam Introduction to CPSC 233 CPSC 233: Introduction to Computers II Object-oriented programming The "nuts and bolts" of programming Object-oriented design And a whole lot ole fun (you’ll have a …)

James Tam Introduction to CPSC 233 Administrative (James Tam: L04) Contact Information Office: ICT 707 Phone: Office hours Office hours: MW 12:00 – 12:50 (any time) Appointment: phone or call Drop by for urgent requests (but no guarantee that I will be in!)

James Tam Introduction to CPSC 233 Feedback ??? Dilbert © United Features Syndicate

James Tam Introduction to CPSC 233 How You Will Be Evaluated Assignments (30%) Assignment 1: Transition from Pascal to Java Assignment 2: Developing your first Java class Assignment 3: Stacks, Object-Oriented Design and Problem Decomposition in a simple game Assignment 4: Composition, Aggregation, Encapsulation; introduction to BNF and text parsing Assignment 5: Inheritance Assignment 6: Encryption (Low-level concepts using "C")

James Tam Introduction to CPSC 233 How You Will Be Evaluated (2) More on assignments Bonus marks for assignments Due dates for assignments (Friday or Monday)

James Tam Introduction to CPSC 233 How You Will Be Evaluated (3) Exams (70%) Midterm exam (25%) Final exam (45%) Note: In order to attain a final grade of C- or higher you must receive a minimum grade of C- on the final exam and submit at least four out of the six assignments (this excludes the bonus assignment)

James Tam Introduction to CPSC 233 Course Resources Course website: (Supplements): Course textbooks: Java by Dissection, Pohl, McDowell (Addison-Wesley) Fundamentals of Object-Oriented Design in UML, Meilir (Addison-Wesley) Recommended textbooks (Unix): A Practical Guide to Solaris, Sobell (Addison-Wesley) (Good alternative) Harley Hahn's Student Guide to Unix, Hahn (McGraw-Hill)

James Tam Introduction to CPSC 233 CPSC 231: What was it like A whole lot of work!

James Tam Introduction to CPSC 233 CPSC 233: What To Expect Even more work!!! But you share it with up to 2 other friends

James Tam Introduction to CPSC 233 Java: History Released in 1995 by Sun (Gosling and Naughton) Blatant advertisement: James Gosling was a graduate of the U of C Computer Science program.

James Tam Introduction to CPSC 233 Java: History (2) Originally Devised to run on many types of (soon to be) intelligent devices

James Tam Introduction to CPSC 233 Java: History (3) The popularity of the Internet resulted in a focus on computers: Prior to the advent of Java web pages allowed you to download text and images. Server containing a web page Your computer at home running a web browser User clicks on a link Images and text get downloaded

James Tam Introduction to CPSC 233 Java: History (4) Java enabled web browsers allowed for downloading of programs (Applets) Server containing a web page Your computer at home running a web browser User clicks on a link Java Applet downloaded Java version of the Game of Life: Online checkers:

James Tam Introduction to CPSC 233 Java: Write Once, Run Anywhere Consequence of having web-based roots: platform- independent Mac user running Netscape Windows user running Internet Explorer Web page stored on Unix server Click on link to Applet Byte code is downloaded Virtual machine translates byte code to native Mac code and the Applet is run Byte code (part of web page)

James Tam Introduction to CPSC 233 Java: Write Once, Run Anywhere Consequence of having web-based roots: platform- independent Mac user running Netscape Windows user running Internet Explorer Web page stored on Unix server Click on link to AppletByte code is downloaded Virtual machine translates byte code to native Windows code and the Applet is run

James Tam Introduction to CPSC 233 Java: Write Once, Run Anywhere (2) But Java can also create standard (non-web based) programs Dungeon Master (Java version) Don’t play this game on the CPSC network!

James Tam Introduction to CPSC 233 Review: Compiling Pascal programs anything.p Pascal program gpc Pascal compiler input a.out Machine language program output

James Tam Introduction to CPSC 233 Compiling Programs On Different Operating Systems Pascal program Solaris compiler a.out (Solaris) AmigaDOS compiler a.out (AmigaDOS) Windows compiler a.out (Windows)

James Tam Introduction to CPSC 233 Creating, Compiling And Running Java Programs: On The Computer Science Network name.java (Unix file) Java program javac Java compiler Java byte code name.class (Unix file) Type it with the text editor of your choice To compile the program, in Unix type "javac filename.java" To run interpreter, in Unix type "java filename" java Java Interpreter

James Tam Introduction to CPSC 233 Smallest Compilable Programs (Pascal, C) (* Pascal-language program *) program smallest; begin end. (* C-language program *) main (int argc, char argv [][]) { }

James Tam Introduction to CPSC 233 Smallest Compilable Java Program /* Java-language program */ class Smallest { public static void main (String[] args) { }

James Tam Introduction to CPSC 233 Basic Output: Pascal And Java Pascal write('..'); writeln('..'); Java System.out.print(“”); System.out.println("..");

James Tam Introduction to CPSC 233 Basic Java Output Format: System.out.println( +..); Examples ( Assumes a variable called num has been declared. ): System.out.println("Good-night gracie!"); System.out.print(num); System.out.println("num=" +num);