+ All Categories
Home > Documents > Introduction to Object-Oriented Programming and Data...

Introduction to Object-Oriented Programming and Data...

Date post: 08-Sep-2019
Category:
Upload: others
View: 3 times
Download: 0 times
Share this document with a friend
23
Introduction to Object-Oriented Programming and Data Structure 2013-2 Object-Oriented Programming and Data Structure September 2, 2013 Prof. Young-Tak Kim Advanced Networking Technology Lab. (YU-ANTL) Dept. of Information & Comm. Eng, Graduate School, Yeungnam University, KOREA (Tel : +82-53-810-2497; Fax : +82-53-810-4742 http://antl.yu.ac.kr/; E-mail : [email protected])
Transcript
Page 1: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Introduction to Object-Oriented Programming and

Data Structure

2013-2 Object-Oriented Programming and Data Structure

September 2, 2013

Prof. Young-Tak Kim Advanced Networking Technology Lab. (YU-ANTL)

Dept. of Information & Comm. Eng, Graduate School, Yeungnam University, KOREA

(Tel : +82-53-810-2497; Fax : +82-53-810-4742 http://antl.yu.ac.kr/; E-mail : [email protected])

Page 2: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 2

Outline

수업 목표 (Objectives of Lecture) 시스템 설계 및 구현 단계 객체지향형 프로그래밍이란 ? 자료 구조와 알고리즘 교재 강의 및 실습 설계 프로젝트 조교

Page 3: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 3

Lecture Overview

Objective Study the C++ Object-oriented programming skill for engineering

problem solving, Data Structure, and system design & implementation

Related practice lab. C++ O-O programming and Data structure practice lab.

Prerequisite Courses: Computer and Internet, Computer Programming (C programming), Programming Language (C/C++)

Page 4: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 4

Cycles in System design and implementation

Source codes .c, .cc

Object codes .o

Program Execution output

Compile

Link Executable codes

.exe

Load

Execute

Correct Output ?

Mission Completed !!

Edit program source code

Analysis of the requirement Evaluate Feasibility

Algorithm design Data structure design

Software system design Subsystem design

Block design Module design

Class / Function design

Design Implementation

Problem Specifications (Requirements,

Objectives)

Syntax Error

Logical Error

Page 5: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 5

Design phase design of algorithm design of data structure

Implementation phase programming language

Which phase should be emphasized more ? if you do not design with good algorithm, your system will not produce

good results at time with efficient utilization of system resources, no matter what programming language is used

without good design, you cannot get good product !

Page 6: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 6

Why Object-Oriented Programming ?

Fundamentally required skill for large-scale system design and implementations System stability (시스템 안정성): 시스템이 항상 정상적인 범위

/상태에 존재하도록 유지. Software re-usability (소프트웨어 재사용성): 기존에 개발된 소프트웨어 모듈을 재사용함으로써 쉽게 새로운 시스템 개발. 시스템 개발 기간과 비용을 절감.

User-friendly Interface (사용자 친화형 접속): 사용자가 쉽게 이해하고, 사용할 수 있는 인터페이스

System expandability (시스템 확장성): 새로운 최신 기술이 개발되었을 때, 이를 쉽게 수용할 수 있는 확장성.

System Manageability (시스템 관리 용이성): 시스템을 쉽게 관리할 수 있는 구조

Page 7: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 7

System stability all data members should contain appropriate data values e.g.) human age: 0 ~ 150 years people’s height: 30 ~ 250 cm water temperature: 0 ~ 100 °C

get() and set() member function for each data members

Software re-use usage of the existing / well-managed software modules reduced development cost minimized development period better reliability inheritance

Page 8: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 8

Use-friendly interface any system should be easy to use easily understood user interface common sense internationally accepted notations (e.g., mathematical operators) operator overloading

System expandability any new technology should be easily adapted without too much

modification well defined/standardized inter-module interface information hiding

System manageability without too much modification in the existing management system, new

product should be easily integrated polymorphism is necessary

Page 9: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 9

Data Structure and Algorithm

Applications require Appropriate Data Processing Pattern (algorithm) Appropriate Data Structure

E.g.) Customer service at bank, ticket booth first come first served (FCFS) rule FIFO (first in first out) queue

E.g.) Information search from 100 Tera-bytes data base linear search vs. binary search considerations: request pattern of update and search hash, binary search tree, multi-way tries

Page 10: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 10

Appropriate data structure and algorithm enhances system performance the most appropriate data structure and algorithm should be used appropriate data structure: (e.g., array of struct vs. binary tree) appropriate algorithm: (e.g., linear search vs. binary search)

major considerations: CPU performance special processing block system memory size processing time required memory size communication link capacity

Page 11: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 11

Text Book and References

Textbook and Major References [1] Walter Savitch, Kenrick Mock, Absolute C++, 4th Ed, Pearson,

2010. [2] Michael T. Goodrich, Roberto Tamassia, David Mount, Data

Structures and Algorithms in C++, 2nd Ed, John Wiley & Sons, 2011.

[3] Horowitz, Sahni, Mehta, Fundamentals of Data Structures, 2nd Ed., Silicon Press, 2007.

[4] Tony Gaddis, Judy Walters, and Godfrey Muganda, Starting out with C++ - Early Objects, 7th Ed., Addison-Wesley, 2011.

[5] Deitel and Deitel, How to Program C++, Prentice Hall, 2005. [6] 천인국, 쉽게 풀어 쓴 C언어 Express, 생능출판사, 2007. [7] 천인국, 공용해, C 언어로 쉽게 풀어쓴 자료구조, 생능출판사,

2009.

Page 12: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 12

Lecture Topics

Part 1: Algorithm and Programming Introduction to computers and programming Flow chart and Pseudo code Algorithm System development procedure Software design document

Page 13: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 13

Part 2: Object-oriented programming Introduction to object-oriented programming Introduction to classes and objects Class Abstraction, Information hiding Inheritance and software reuse Polymorphism, virtual functions Linked list with C++ classes Stack and Queues Binary tree Standard Template Library (STL)

Page 14: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 14

Part 3: Data Structure Basic concepts of data structure Arrays, dynamic arrays, sparse matrices, Stacks and Queues Linked Lists Trees Graphs Sorting Hashing Priority Queues, Heaps Efficient binary search trees Multi-way search trees, B-trees Digital search structures, binary tries, multi-way tries

Page 15: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 15

Lectures and Labs

강의 (Lectures) 3 hours classes per week

실습 (Practice Labs) 2 hours practice lab per week

보충설명 2 hours additional TA explanation class per week

Page 16: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 16

Examinations, and Reports 4 examinations mid-term 1: October 5, 2013 (Sat) mid-term 2: October 23, 2013 (Wed) mid-term 3: November 23, 2013 (Sat) final : December 18, 2013 (Wed)

Oral test and Quiz: after each test Homework is assigned for each chapter Each homework must be submitted as separated report

Report due : after 1 week, at lecture classroom only Overdue policy : at each 1 week delay, 20 % reduction from the

total score

Page 17: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 17

설계 프로젝트

Design Project (설계 프로젝트) 4 weeks design project for ABEEK program design document implementation presentation design project report

Page 18: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 18

Goal of design project Topic: design and implementation of a high speed packet

routing/forwarding module 1 Gbps link speed packets of 100 Bytes 200,000 possible destinations

necessary algorithms and data structures: input packet queuing fast search (routing/forwarding table lookup) algorithm output packet queuing

Page 19: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 19

성적 평가

Evaluation & Grading Exam 100 x 4 points Lab. (실습) 200 points Design Project (설계프로젝트) 200 points Class attendance 100 points Report 100 points total 1,000 points

Page 20: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 20

Lecture Supports

Teaching Assistant (TA) Hyung-Dong Hwang ( 황 현 동 ): Advanced Networking

Technology Lab. (ANTL, IT Building, Room 304) Telephone : 053-810-3940, Fax : 053-810-4742 E-mail: [email protected]

Lecture homepage: Yeungnam Lecture Assistant System http://cyber.yu.ac.kr/lecture/index.phtml, 객체지향형 프로그래밍과 자료구조 (Lecture )

Page 21: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 21

15 Key Topics in Programming with C/C++

<Part 1: C++ Object-Oriented Programming> 1) class and object: class definition and implementation (private data

member, member function), encapsulation, information hiding 2) operator overloading: +, -, *, /, ==, !=, ++, --, ! (determinant of

matrix), ~ (inverse of matrix) 3) inheritance of classes 4) virtual function and polymorphism 5) Linked and binary tree with C++ class 6) Standard template library (STL)

Page 22: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 22

<Part 2: Data Structure> 7) Arrays, dynamic arrays, sparse matrices, 8 Linked Lists 9) Stacks and Queues 10) Trees 11) Efficient binary search trees 12) Graphs 13) Hashing 14) Priority Queues, Heaps 15) Multi-way search trees, B-trees

Page 23: Introduction to Object-Oriented Programming and Data Structurecontents.kocw.net/KOCW/document/2013/youngnam/YoungTakKim/1-1.pdf · 자료 구조와 알고리즘 교재 강의 및

Advanced Networking Tech. Lab. Yeungnam University (YU-ANTL)

O-O Programming & Data Structure Prof. Young-Tak Kim ch 0 - 23

Questions and Answer on the Lecture

Q & A


Recommended