COMP 2011 Data Organisation 2005 Session 1

Slides:



Advertisements
Similar presentations
CS1020 Week 3: 29th January 2015.
Advertisements

Data Structures and Algorithms (AT70.02) Comp. Sc. and Inf. Mgmt. Asian Institute of Technology.
COMP171 Data Structures and Algorithms Spring 2009.
COMP171 Data Structures and Algorithms Spring 2009.
July Overview1 COMP 2011 Data Organisation 2004 Session 2 Lecturer: Alan Blair Head Tutor: Loc Huynh.
S Overview1 COMP 2011/2711 Data Organisation 2006 Session 1 Lecturer: Norman Foo Head Tutor: Loc Huynh; others to be nominated.
March 2004Object Oriented Design1 Object-Oriented Design.
Files and Streams CS 21a Chapter 11 of Horstmann.
James Tam Simple File Input And Output Types of Java Files Simple File Output in Java Simple File Input in Java.
COMP171 Data Structures and Algorithm Qiang Yang Lecture 1 ( Fall 2006)
METU Computer Engineering Department
Instructor: Dr. Sahar Shabanah Fall Lectures ST, 9:30 pm-11:00 pm Text book: M. T. Goodrich and R. Tamassia, “Data Structures and Algorithms in.
CSC3170 Introduction to Database Systems
CPS 2231 Computer Organization and Programming Instructor: Tian (Tina) Tian.
© 2004 Goodrich, Tamassia CS2210 Data Structures and Algorithms Lecture 1: Course Overview Instructor: Olga Veksler.
INTRODUCTION TO DATA STRUCTURES AND ALGORITHMS Marcus Frean School of Engineering and Computer Science, Victoria University of Wellington COMP T2.
© Xiaoying Gao, Peter Andreae Introduction to Computer Program Design COMP T2. Xiaoying (Sharon) Gao Computer Science Victoria University of Wellington.
Geoff Holmes and Bernhard Pfahringer COMP206-08S General Programming 2.
CSCI 51 Introduction to Computer Science Dr. Joshua Stough January 20, 2009.
ASDA: Prelim/ Advanced Data Structures and Algorithms Objective – –to give some background on the course Semester 2, Who I am: Andrew.
Data Structures (Second Part) Lecture 1 Bong-Soo Sohn Assistant Professor School of Computer Science and Engineering Chung-Ang University.
COMP2012 Object-Oriented Programming and Data Structures Fall 2015.
CS 206 Introduction to Computer Science II 09 / 10 / 2009 Instructor: Michael Eckmann.
1 CSE1301 Computer Programming: Revision. 2 Topics Type of questions What do you need to know? About the exam Exam technique Staff consultation Revision.
© Xiaoying Gao, Peter Andreae Introduction to Computer Program Design COMP T2. Xiaoying (Sharon) Gao Computer Science Victoria University of Wellington.
Chapter 15 Text Processing and File Input/Output Lecture Slides to Accompany An Introduction to Computer Science Using Java (2nd Edition) by S.N. Kamin,
COMP1927 Course Introduction 16x1
Exceptions. Exception  Abnormal event occurring during program execution  Examples Manipulate nonexistent files FileReader in = new FileReader("mumbers.txt“);
King Saud University1 CSC 112 Java Programming I Introduction.
Course Info Instructor U.T. Nguyen Office: CSEB Office hours: Tuesday, 14:30-15:30 Thursday, 12:00-12:45 By.
Data Structures and Algorithms in Java AlaaEddin 2012.
COMP 103 wrapping up and some exam tips 2015-T2 Lecture 32 Marcus Frean School of Engineering and Computer Science, Victoria University of Wellington 
Principles of Imperative Computation Lecture 1 January 15 th, 2012.
1 CENG 707 Data Structures and Algorithms Nihan Kesim Çiçekli Department of Computer Engineering Middle East Technical University Fall 2013.
CENG 213 Data Structures1 Nihan Kesim Çiçekli Department of Computer Engineering Middle East Technical University.
COMP9024: Data Structures and Algorithms Course Outline Hui Wu Session 1, 2016
CS16: Introduction to Algorithms and Data Structures
CENG 213 Data Structures Nihan Kesim Çiçekli
CENG 707 Data Structures and Algorithms
CS210 Intermediate Computing with Data Structures (Java)
Computer Engineering Department Islamic University of Gaza
COMP9024: Data Structures and Algorithms
OO Design and Programming II I/O: Reading and Writing
UMBC CMSC 104 – Section 01, Fall 2016
DDC 2423 DATA STRUCTURE Main text:
CENG 213 Data Structures Nihan Kesim Çiçekli
CENG 213 Data Structures Dr. Cevat Şener
CSC215 Lecture Orientation.
Computer Science 102 Data Structures CSCI-UA
ECET 370 HELPS Lessons in Excellence- -ecet370helps.com.
ECET370 Education for Service-- ecet370.com. ECET 370 Entire Course (Devry) For more course tutorials visit ECET 370 Week 1 Lab 1 ECET.
ECET 370 HELPS Education for Service- - ecet370helps.com.
CS 201 – Data Structures and Discrete Mathematics I
Welcome to CS 1010! Algorithmic Problem Solving.
Reading and Writing Text Files
Introduction CSE 373 Data Structures.
CENG 213 Data Structures Nihan Kesim Çiçekli
Welcome to CS 1301! Principles of Programming I.
Computer Programming 1 introduction to JAVA Lecture 1 Instructor: Ruba A. Salamah Islamic University of Gaza.
Review CSE116 2/21/2019 B.Ramamurthy.
Computer Graphics Course Introduction.
CMSC201 Computer Science I for Majors Final Exam Information
ICS201 Introduction To Computing II
Orientation CSC 111.
Principles of Imperative Computation
Computer Engineering Department Islamic University of Gaza
Exceptions.
Exceptions.
Java Coding 6 David Davenport Computer Eng. Dept.,
David Davenport Spring 2005
Presentation transcript:

COMP 2011 Data Organisation 2005 Session 1 2011 Overview 8/7/2018 7:55 PM COMP 2011 Data Organisation 2005 Session 1 Lecturer: Alan Blair Head Tutor: Loc Huynh Guest Lecturer: Prof. Norman Foo March 2005 2011 Overview

Prerequisites for 2011 COMP1011 Computing 1A Haskell structured problem decomposition abstract data types COMP1021 Computing 1B procedural programming with C control flow (if, for, while, switch) March 2005 2011 Overview

Resources www.cse.unsw.edu.au/~cs2011 Textbook Other Reference Books Data Structures and Algorithms in Java (3rd Ed.) by Goodrich & Tamassia www.cse.unsw.edu.au/~cs2011 lecture slides, announcements links to Java API assignments, tutorial exercises Other Reference Books Java Programming Language (3rd Ed.) Core Java 2 Java in a Nutshell March 2005 2011 Overview

Syllabus Java & Object-Oriented Programming Analysis of Algorithms Stacks, Queues, Trees Heaps, Hash Tables, Search Trees Sorting Algorithms Text Processing Graphs March 2005 2011 Overview

Assessment 3 Assignments (40%) Exam (60%) to pass the course you must achieve at least 20 out of 60 for the exam at least 50 out of 100 overall March 2005 2011 Overview

Plagiarism Policy Assignments must be entirely your own work DON’T copy from others DON’T let anyone see your code we use plagiarism detection programs, which work very well first detection: negative mark for assignment second detection: failure of course third detection: possible expulsion from Uni March 2005 2011 Overview

What TO DO in general keep up with lectures and tutorials read textbook and lecture slides attempt tutorial questions before the tutorial read Java programming guides and tutorials books or online practice Java programming laboratory consultations (mon 12-1, thu 2-3) use tutorial exercises for practice assignments alone are not enough March 2005 2011 Overview

What TO DO this week buy the textbook, and read chapter 1 register with sirius (in CSE labs) install Java 2 SDK on own PC (JDK1.4 or 1.3) may need to set PATH and CLASSPATH Java 2 online tutorial Your first cup of Java Getting Started Learning the Java Language Week 2 tutorial questions March 2005 2011 Overview

For Help Java installation at home Java programming JDK 1.3 home computing CD from CompSoc, or online CSE helpdesk Java online docs Java programming labs consultations your tutor friends Tutorials/Assignments Check FAQ on 2011 website 2011 consultants email alias then your tutor then the lecturer Admin problems email: cs2011@cse.unsw.edu.au always use your CSE mail account, or include your student ID last resort, contact the lecturer-in-charge (Alan Blair) March 2005 2011 Overview

Example Program Copy.java (program for copying a file) $ ls Copy.java file1 $ javac Copy.java $ java Copy file1 file2 $ ls Copy.class Copy.java file1 file2 $ diff file1 file2 $ March 2005 2011 Overview

copy.c Copy.java #include <stdio.h> #define MAX_LINE 256 void copy( char *source, char *dest ); int main( int argc, char *argv ) { if( argc != 3 ) { printf( “Usage: copy <source> <dest>\n”); } else { copy( argv[1], argv[2] ); return 0; } ... import java.io.*; public class Copy { public static void main( String[] args ) if( args.length != 2 ) { System.out.println( “Usage: java Copy <source> <dest>” ); } else { copy( args[0], args[1] ); ... March 2005 2011 Overview

copy.c Copy.java void copy( char *source, char *dest ) { FILE *fileIn; FILE *fileOut; char oneLine[MAXLINE]; fileIn = fopen( source, “r” ); if( FileIn == NULL ) { printf( “Error: file not found\n” ); exit( 1 ); } fileOut = fopen( source, “w” ); if( fileOut == NULL ) { while( fgets(oneLine,MAXLINE,fileIn ) != NULL ) { fputs( oneLine, fileOut ); fclose( fileIn ); fclose( fileOut ); public static void copy(String source, String dest) { BufferedReader fileIn; PrintWriter fileOut; try { fileIn = new BufferedReader( new FileReader( source )); fileOut = new PrintWriter( new FileWriter( dest )); String oneLine; while(oneLine = fileIn.readLine()) != null ) { fileOut.println( oneLine ); } fileIn.close(); fileOut.close(); catch( IOException e ) { System.out.println( “Error :” + e ); System.exit( 1 ); March 2005 2011 Overview

Next Time Why Java? Object Oriented Design Classes, Types, Objects Methods Expressions Control Flow Arrays Input / Output Packages March 2005 2011 Overview