Introduction to Programming ( 計算機程式設計 ) Chapter 1 Getting Ready

Size: px
Start display at page:

Download "Introduction to Programming ( 計算機程式設計 ) Chapter 1 Getting Ready"

Transcription

1 Introduction to Programming ( 計算機程式設計 ) Chapter 1 Getting Ready Meng-Lin Li ( 李夢麟 ) mlli@ee.nthu.edu.tw Department of Electrical Engineering National Tsing Hua University 1

2 Why C, C, Why not C++? Spirit of ofc++ --Object-Oriented Programming (OOP) 2

3 What computers do C s features What Will You Learn? Steps needed to write programs Compilers and linkers C Standards 3

4 What computers do C s features What Will You Learn? Steps needed to write programs Compilers and linkers C Standards 4

5 A computer Programming Environment A workstation ( 工作站 ) : Sun ( 昇陽 ) SPARCstation-10 A personal computer (PC) : Acer ( 宏碁 ) FT100 Computer hardware ( 計算機硬體 ) Hardware environment Computer software ( 計算機軟體 ) Software environment 5

6 Pictures of of4th Generation Computer 6

7 Computer Hardware von Neumann architecture CPU System bus I/O bus Secondary storage memory I/O devices 7

8 Computer Hardware Bus A high-speed communication channel between hardware components of a computer Central processing unit (CPU, 中央處理單元 ) Brain of the computer, performing computation and controlling the computer Main memory ( 主記憶體 ) Hardware that is capable of quickly storing and retrieving information RAM (random access memory) in a workstation Secondary memory ( 次記憶體 ) Large-volume storage device that dose not require electrical power to store permanent data. hard disk 8

9 Peripherals ( 週邊設備 ) Computer Hardware Hardware devices that perform input and output functions Interactive ( 互動式 ) communication between users and machines Keyboard ( 鍵盤 ) : standard input ( stdin, in C) device Monitor ( 監視器 ) : standard output ( stdout, in C) device Printer ( 印表機 ) : output device 9

10 Computer Software Operating system ( 作業系統 ) A software system to coordinate all the resources in a computer UNIX (based), Windows 10

11 CPU and Memory (Fetch and Execute) reg 0 Register 0 Program counter 0x x00 Memory add R4, R1, R2 reg Instruction register 0x04 reg add R4, R1, R2 0x08 reg 3 0x0c reg x10 reg 5 Control logic 0x ALU Memory Address Register to/from memory 11

12 Data Path for Register File Program Execution reg 0 Register 0 Program counter 0x x00 Memory add R4, R1, R2 reg Instruction register 0x04 reg add R4, R1, R2 0x08 reg 3 0x0c reg x10 reg 5 Control logic 0x ALU Memory Address Register to/from memory 12

13 Program Execution of of Addition (Simplified Version) Fetch Copy the instruction in memory Copy the number in memory location 2000 to register 1 Copy the number in memory location 2004 to register 2 Add the contents of register 2 to the contents of register 1, leaving the answer in register 1 Copy the contents of register 1 to memory location 2008 Execute 13

14 Program Execution Follows Machine Language (Binary, the world of 0 and 1) 14

15 An Example MIPS code (Binary representation) Guess what the MIPS code does? The c code a = b + c (High level language understandable to us) is transformed into the machine code By what? 15

16 What computers do C s features What Will You Learn? Steps needed to write programs Compilers and linkers C Standards 16

17 Why C instead of ofother fancy languages, like Basic, Fortran, Pascal, Delphi, C++, C#, JAVA, Matlab, Labview and so soon? (What? $%^& Google it!) 17

18 High level language Understandable to us Why C? Design features Top-down planning, structured programming, and modular design Efficiency Portability C programs written on one system can be run on other systems with little or no modification (C compilers are available for about 40 systems) Power and flexibility Programmer Oriented Access to hardware, manipulate individual bits in memory Shortcomings The danger comes with the flexibility C s freedom requires added responsibility to the programmers 18

19 What computers do C s features What Will You Learn? Steps needed to write programs Compilers and linkers C Standards 19

20 Seven Steps of ofprogramming 7. Maintain and modify the program 6. Test and debug ( 除錯 ) the program (Bugs, Mistakes) 5. Run the program (Executable file) 4. Compile 3. Write the code (Source code) 2. Design the program with a flow chart ( 流程圖 ) 1. Define the program objects 20

21 Write the Codes by by Text Editor Text editor ( 編輯器 ) An interface software for a user to write a C program The program will be stored in the file system as a file with a name ended in.c, called a source code file hello.c wordcount.c power.c basename extension Filename ( 副檔名 ) 工具 -> 資料夾選項 -> 檢視 ->Disable 隱藏副檔名 <HINT> I prefer *.cpp as the extension. Why? 21

22 22

23 Text Editors in inunix System vi A standard text editor in UNIX with high efficiency vim An improved version of vi in UNIX Official website Good tutorial website: GNU emacs 23

24 Text Editors in inwindows NotePad ( 附屬應用程式 -> 記事本 ), not WordPad) UltraEdit-32 24

25 A C Program hello.c ( Text file) /* The famous C program in K&R which prints the words hello, world. */ #include <stdio.h> int main(void) { printf( hello, world\n ); return 0; } How and where to write it? Demo in Windows 1. Pure text editor 2. IDE (Integrated development environment, e.g., Dev-C++) 25

26 Notepad->Create *.txt->rename it to *.cpp->double click to edit 26

27 What computers do C s features What Will You Learn? Steps needed to write programs Compilers and linkers C Standards 27

28 Compiler And Linker Compiler ( 編譯器 ) To translate a C program s source code file to an object code file (a machine language code) Linker ( 連結器 ) To link the user object code with two other system object codes into an executable file (a complete machine language code) The standard start-up code an interface between your program and the operating system The standard C library code routines called by the user object code 28

29 A Translation Hierarchy (( 階級制 )) C program source code Complier Assembly language program Assembler Object code:machine language module Object:Start-up code (machine language) Object : Library routines (machine language) Linker Executable code:machine language program Loader Memory 29

30 C Compilers in inunix System cc The standard compiler in Unix system The compiler command is cc inputfilename gcc Created as a part of the GNU operating system The compile command is gcc o outputfilename inputfilename 30

31 C Compilers in inwindows Free Dev-C++ (Demo compiling and running the program) Visual C++ Borland C++ (Builder) 31

32 32

33 What computer do C s features What Will You Learn? Steps needed to write programs Compilers and linkers C Standards 33

34 Whence C? Dennis Ritchie of Bell Labs created C in 1972 as he and Ken Thompson worked on designing the Unix operating system. It was named "C" because many of its features were derived from an earlier language Thompson s B language 34

35 K&R C or classic ( 古典 ) C Evolution (( 演化 )) of ofc K&R means Brian Kernighan and Dennis Ritchie Based on the 1st edition ( 第一版 ) of their book The C Programming Language in 1978 The C language is defined but not the C library ( 函式庫 ) The C library in the UNIX implementation became a de facto ( 實質上的 ) standard ( 標準 ) 35

36 ANSI/ISO C Evolution (( 演化 )) of ofc Both the C language and a standard C library are defined ANSI = American National Standards Institute ANSI C at 1989 ISO = International Organization of Standardization ISO C at 1990 ANSI C and ISO C are essentially the same and referred to as C90 36

37 Evolution (( 演化 )) of ofc C99 Standard The newest standard established by a joint ANSI/ISO committee Keeping the spirit of C small, simple and efficient Internationalization ( 國際化 ) Dealing with international character sets Correction of deficiency ( 缺點 ) Codify ( 編纂 ) existing practice to address evident deficiencies Meeting the needs of moving C to 64-bit processors Improvement of computational usefulness 37

38 Last Thing You Have to toknow in inadvance 38

39 Number Systems Decimal (base 10) number system ( 十進位 ) 109 = 1 x 10^2 + 0 x 10^1 + 9 x 10^0 Binary (base 2) number system ( 二進位 ) = 1 x 2^6 + 1 x 2^5 + 0 x 2^4 + 1 x 2^3 + 1 x 2^2 + 0 x 2^1 + 1 x 2^0 = 109 (base 10) Octal (base 8) number system ( 八進位 ) 0155 = 1 x 8^2 + 5 x 8^1 + 5 x 8^0 = 109 (base 10) = Hexadecimal (base 16) number system ( 十六進位 ) 0x6d = 6 x 16^ x 16^0 = 109 (base 10) = a = 10, b = 11, c = 12, d = 13, e = 14, f = 15 39

40 Data type Main Chapter Organization Strings, and formatted input and output Operators, expressions, and statements Looping Condition control: branching and jumps Functions Array and pointers File input/output 40

41 What computers do C s features Have You Learned? Steps needed to write programs Compilers and linkers C Standards (Number Systems) 41

42 Take Home Practices Create the text file hello.cpp and write the most famous C program Hello, the world! by the introduced text editors If you like to, try to compile and run the program by the ways introduced in in-class demos. 42

43 Welcome to tothe World of ofc ^_^ 43

Operating Systems 作業系統

Operating Systems 作業系統 Chapter 7 Operating Systems 作業系統 7.1 Source: Foundations of Computer Science Cengage Learning Objectives 學習目標 After studying this chapter, students should be able to: 7.2 Understand the role of the operating

More information

EL2310 Scientific Programming

EL2310 Scientific Programming Lecture 6: Introduction to C (pronobis@kth.se) Overview Overview Lecture 6: Introduction to C Roots of C Getting started with C Closer look at Hello World Programming Environment Schedule Last time (and

More information

微處理機系統 吳俊興高雄大學資訊工程學系. February 21, What are microprocessors (µp)? What are the topics of this course? Why to take this course?

微處理機系統 吳俊興高雄大學資訊工程學系. February 21, What are microprocessors (µp)? What are the topics of this course? Why to take this course? 微處理機系統 吳俊興高雄大學資訊工程學系 February 21, 2005 processor, central processing unit (CPU) A silicon chip which forms the core of a microcomputer The heart of the microprocessor-based computer system Concept of what

More information

EL2310 Scientific Programming

EL2310 Scientific Programming (yaseminb@kth.se) Overview Overview Roots of C Getting started with C Closer look at Hello World Programming Environment Discussion Basic Datatypes and printf Schedule Introduction to C - main part of

More information

by Pearson Education, Inc. All Rights Reserved.

by Pearson Education, Inc. All Rights Reserved. Programmers write instructions in various programming languages, some directly understandable by computers and others requiring intermediate translation steps. Computer languages may be divided into three

More information

CS133 C Programming. Instructor: Jialiang Lu Office: Information Center 703

CS133 C Programming. Instructor: Jialiang Lu   Office: Information Center 703 CS133 C Programming Instructor: Jialiang Lu Email: jialiang.lu@sjtu.edu.cn Office: Information Center 703 1 Course Information: Course Page: http://wirelesslab.sjtu.edu.cn/~jlu/teaching/cp2014/ Assignments

More information

香港中文大學學生會計算機科學系會 圖書清單

香港中文大學學生會計算機科學系會 圖書清單 香港中文大學學生會計算機科學系會 圖書清單 100 Theory 120 CGI 140 Visual Basic 160 Other Programming Book 101 Program budgeting and benefit-cost analysis 102 Introduction to Algorithms 103 Introduction to Algorithms 104 Data

More information

一般來說, 安裝 Ubuntu 到 USB 上, 不外乎兩種方式 : 1) 將電腦上的硬碟排線先予以排除, 將 USB 隨身碟插入主機, 以一般光碟安裝方式, 將 Ubuntu 安裝到 USB

一般來說, 安裝 Ubuntu 到 USB 上, 不外乎兩種方式 : 1) 將電腦上的硬碟排線先予以排除, 將 USB 隨身碟插入主機, 以一般光碟安裝方式, 將 Ubuntu 安裝到 USB Ubuntu 是新一代的 Linux 作業系統, 最重要的是, 它完全免費, 不光是作業系統, 連用軟體都不必錢 為什麼要裝在 USB 隨身碟上? 因為, 你可以把所有的軟體帶著走, 不必在每一台電腦上重新來一次, 不必每一套軟體裝在每一台電腦上都要再一次合法授權 以下安裝方式寫的是安裝完整的 Ubuntu- 企業雲端版本 V. 11.10 的安裝過程, 若是要安裝 Desktop 版本, 由於牽涉到

More information

VB 拼圖應用 圖形式按鈕屬性 資科系 林偉川

VB 拼圖應用 圖形式按鈕屬性 資科系 林偉川 VB 拼圖應用 資科系 林偉川 圖形式按鈕屬性 Style 屬性 0 ( 標準外觀 ),1( 圖片外觀 ) Picture 屬性 圖形檔案 (VB6) image 屬性 圖形檔案 (VB.NET) Left=Top=0 Width=2052,Height=2052 共有九張圖 1.jpg 9.jpg Form1 執行時視窗為最大化 Windowstate 設為 2 2 1 執行結果 3 path$

More information

第九章結構化查詢語言 SQL - 資料定義語言 (DDL) 資料庫系統設計理論李紹綸著

第九章結構化查詢語言 SQL - 資料定義語言 (DDL) 資料庫系統設計理論李紹綸著 第九章結構化查詢語言 SQL - 資料定義語言 (DDL) 資料庫系統設計理論李紹綸著 SQL 的資料定義語言 本章內容 建立資料表 修改資料表 刪除資料表 FOREIGN KEY 外鍵條件約束與資料表關聯性 2 資料定義語言可分為下列三種 : SQL 的資料定義語言 CREATE TABLE 指令 : 用來建立一個基底關聯表, 和設定關聯表相關的完整性限制 CREATE VIEW 指令 : 用來建立一個視界,

More information

PC Link Mode. Terminate PC Link? Esc. [GO]/[Esc] - - [GO]/[Esc] 轉接座未放滿. Make auto accord with socket mounted? [GO]/[Esc] Copy to SSD E0000

PC Link Mode. Terminate PC Link? Esc. [GO]/[Esc] - - [GO]/[Esc] 轉接座未放滿. Make auto accord with socket mounted? [GO]/[Esc] Copy to SSD E0000 Start SU-6808 EMMC Programmer V.0bd7 [ ]Link PC / [ ]Menu [ ] >.Select project.make new project.engineer mode.reset counter 5.Link to PC [ ] PC disconnected PC connected Select project SEM0G9C_A.prj Terminate

More information

UAK1-C01 USB Interface Data Encryption Lock USB 資料加密鎖. Specifications for Approval

UAK1-C01 USB Interface Data Encryption Lock USB 資料加密鎖. Specifications for Approval Product Definition C-MING Product Semi-finished Product OEM/ODM Product Component USB Interface Data Encryption Lock USB 資料加密鎖 Specifications for Approval Approval Manager Issued By Revision History Revision

More information

The transformation relationship between defense enterprise architecture and C4ISR system architecture

The transformation relationship between defense enterprise architecture and C4ISR system architecture The transformation relationship between defense enterprise architecture and C4ISR system architecture Dr. Meng-chyi Harn 報告人 : 韓孟麒博士德明財經科技大學資訊科技系 C4ISR 研究中心 Introducing Takming Outline Introduction Fundamental

More information

System-on-Chip (SOC) 晶 系統組

System-on-Chip (SOC) 晶 系統組 專題 學程說明會 System-on-Chip (SOC) 晶 系統組 葉經緯 王進賢 朱元三 蔡宗亨 崇勛 林柏宏 What s hot in your life? More Deeply! Information Navigation Social Activity Translation Face Recognition - Searching SoC Applications Consumer

More information

CSCI2467: Systems Programming Concepts

CSCI2467: Systems Programming Concepts CSCI2467: Systems Programming Concepts Slide set 1: A Tour of Computer Systems (CS:APP Chapter 1) Instructor: M. Toups Spring 2018 Overview 1 A Tour of Computer Systems Systems Information is bits plus

More information

ITC213: STRUCTURED PROGRAMMING. Bhaskar Shrestha National College of Computer Studies Tribhuvan University

ITC213: STRUCTURED PROGRAMMING. Bhaskar Shrestha National College of Computer Studies Tribhuvan University ITC213: STRUCTURED PROGRAMMING Bhaskar Shrestha National College of Computer Studies Tribhuvan University Lecture 04: Introduction to C Readings: Chapter 1.5-1.7 What is C? C is a general-purpose, structured

More information

Programming for Engineers: Getting Started

Programming for Engineers: Getting Started Programming for Engineers: Getting Started 10 January 2011 History of C: Timeline 1. 1972 Ken Thompson working on UNIX 2. 1972 Dennis Ritchie creates C 3. 1983 ANSI C (C89) 4. 1990 ISO C (C90) 5. 1999

More information

Introduction to C Programming

Introduction to C Programming 13205 C Programming Lecture 1-26/Sept/2017 c 2017 Abel Gomes All Rights Reserved Introduction to C Programming Scribe: A. Gomes This lecture aims to respond to the following questions: Why do we need to

More information

Chapter 1 Overview of Programming and Problem Solving By C.K. Liang

Chapter 1 Overview of Programming and Problem Solving By C.K. Liang 1 Chapter 1 Overview of Programming and Problem Solving By C.K. Liang Introduction 2 Why should we have to learn how to program? To learn a skill To find a job To solve a problem To understand the logic

More information

Introduction to Basis and Practice in Programming

Introduction to Basis and Practice in Programming Introduction to Basis and Practice in Programming Fall 2015 Jinkyu Jeong (jinkyu@skku.edu) 1 Course Overview Course Basics! Class hour GEDB029-45: Mon. 13:00 ~ 14:50 GEDB029-46: Tue. 13:00 ~ 14:50 1~2

More information

CLAD 考前準備 與 LabVIEW 小技巧

CLAD 考前準備 與 LabVIEW 小技巧 CLAD 考前準備 與 LabVIEW 小技巧 NI 技術行銷工程師 柯璟銘 (Jimmy Ko) jimmy.ko@ni.com LabVIEW 認證 Certified LabVIEW Associate Developer (LabVIEW 基礎認證 ) Certified LabVIEW Associate Developer LabVIEW 全球認證 40 題 (37 題單選,3 題複選

More information

Version Control with Subversion

Version Control with Subversion Version Control with Subversion 指導教授郭忠義 邱茂森 95598051 1 Table of contents (1) Basic concepts of subversion (1)What is Subversion (2)Version Control System (3)Branching and tagging (4) Repository and Working

More information

桌上電腦及筆記本電腦安裝 Acrobat Reader 應用程式

桌上電腦及筆記本電腦安裝 Acrobat Reader 應用程式 On a desktop or notebook computer Installing Acrobat Reader to read the course materials The Course Guide, study units and other course materials are provided in PDF format, but to read them you need a

More information

Information is EVERYTHING 微軟企業混和雲解決方案. November 24, Spenser Lin. Cloud Infra Solution Sales, Microsoft Taiwan

Information is EVERYTHING 微軟企業混和雲解決方案. November 24, Spenser Lin. Cloud Infra Solution Sales, Microsoft Taiwan Information is EVERYTHING 微軟企業混和雲解決方案 November 24, 2016 Spenser Lin Cloud Infra Solution Sales, Microsoft Taiwan Value to business Applications and services drive future IT business value Efficiency Innovation

More information

Chapter 1: An Overview of Computers and Programming Languages. Objectives. Objectives (cont d.) Introduction

Chapter 1: An Overview of Computers and Programming Languages. Objectives. Objectives (cont d.) Introduction Chapter 1: An Overview of Computers and Programming Languages Objectives Objectives (cont d.) In this chapter, you will: Learn about different types of computers Explore hardware and software Learn about

More information

SSL VPN User Manual (SSL VPN 連線使用手冊 )

SSL VPN User Manual (SSL VPN 連線使用手冊 ) SSL VPN User Manual (SSL VPN 連線使用手冊 ) 目錄 前言 (Preface) 1. ACMICPC 2018 VPN 連線說明 -- Pulse Secure for Windows ( 中文版 ):... 2 2. ACMICPC 2018 VPN 連線說明 -- Pulse Secure for Linux ( 中文版 )... 7 3. ACMICPC 2018

More information

Spring 2018 NENG 202 Introduction to Computer Programming

Spring 2018 NENG 202 Introduction to Computer Programming Spring 2018 NENG 202 Introduction to Computer Programming Introductory programming course based on the C language Course Website: http://www.albany.edu/~yx152122/neng202-18.html Instructor: Prof. Y. Alex

More information

History of C Programming Language. Why Name C was given to Language? Summary of C Programming Language History. C Programming Language Timeline:

History of C Programming Language. Why Name C was given to Language? Summary of C Programming Language History. C Programming Language Timeline: History of C Programming Language C is a programming language which born at AT & T s Bell Laboratory of USA in 1972. C was written by Dennis Ritchie, that s why he is also called as father of c programming

More information

BIL 104E Introduction to Scientific and Engineering Computing. Lecture 1

BIL 104E Introduction to Scientific and Engineering Computing. Lecture 1 BIL 104E Introduction to Scientific and Engineering Computing Lecture 1 Introduction As engineers and scientists why do we need computers? We use computers to solve a variety of problems ranging from evaluation

More information

Lecture 03 Bits, Bytes and Data Types

Lecture 03 Bits, Bytes and Data Types Lecture 03 Bits, Bytes and Data Types Computer Languages A computer language is a language that is used to communicate with a machine. Like all languages, computer languages have syntax (form) and semantics

More information

港專單一登入系統 (SSO) 讓本校的同學, 全日制及兼職老師只要一個登入帳戶, 便可同時使用由本校提供的網上系統及服務, 包括 Blackboard 網上學習平台, 港專電郵服務, 圖書館電子資料庫及其他教學行政系統.

港專單一登入系統 (SSO) 讓本校的同學, 全日制及兼職老師只要一個登入帳戶, 便可同時使用由本校提供的網上系統及服務, 包括 Blackboard 網上學習平台, 港專電郵服務, 圖書館電子資料庫及其他教學行政系統. 港專單一登入系統 (SSO) 讓本校的同學, 全日制及兼職老師只要一個登入帳戶, 便可同時使用由本校提供的網上系統及服務, 包括 Blackboard 網上學習平台, 港專電郵服務, 圖書館電子資料庫及其他教學行政系統. 港專單一登入網站網址 http://portal.hkct.edu.hk (HKCT 之教職員, 學生 ) http://portal.ctihe.edu.hk (CTIHE 之教職員,

More information

PROGRAMMAZIONE I A.A. 2017/2018

PROGRAMMAZIONE I A.A. 2017/2018 PROGRAMMAZIONE I A.A. 2017/2018 PROGRAMMING LANGUAGES A programming language is a formal language that specifies a set of instructions that can be used to produce various kinds of output. Programming languages

More information

Figure 1 Microsoft Visio

Figure 1 Microsoft Visio Pattern-Oriented Software Design (Fall 2013) Homework #1 (Due: 09/25/2013) 1. Introduction Entity relation (ER) diagrams are graphical representations of data models of relation databases. In the Unified

More information

Lecture 1: Preliminaries

Lecture 1: Preliminaries Lecture 1: Preliminaries Edgardo Molina Department of Computer Science City College of New York August 30, 2011 Edgardo Molina (CS@CCNY) Lecture 1 August 30, 2011 1 / 44 Info and Schedule Course Info and

More information

Introduction to Computer Systems

Introduction to Computer Systems CS-213 Introduction to Computer Systems Yan Chen Topics: Staff, text, and policies Lecture topics and assignments Lab rationale CS 213 F 06 Teaching staff Instructor TA Prof. Yan Chen (Thu 2-4pm, Tech

More information

Instructor. Mehmet Zeki COSKUN Assistant Professor at the Geodesy & Photogrammetry, Civil Eng. (212)

Instructor. Mehmet Zeki COSKUN Assistant Professor at the Geodesy & Photogrammetry, Civil Eng. (212) Instructor Mehmet Zeki COSKUN Assistant Professor at the Geodesy & Photogrammetry, Civil Eng. (212) 285-6573 coskunmeh@itu.edu.tr http://atlas.cc.itu.edu.tr/~coskun Address Consultation of Students: Monday

More information

JAVA Programming Language Homework V: Overall Review

JAVA Programming Language Homework V: Overall Review JAVA Programming Language Homework V: Overall Review ID: Name: 1. Given the following Java code: [5 points] 1. public class SimpleCalc { 2. public int value; 3. public void calculate(){ value = value +

More information

Introduction to Computer Systems

Introduction to Computer Systems Introduction to Computer Systems Today:! Welcome to EECS 213! Lecture topics and assignments Next time:! Bits & bytes! and some Boolean algebra Fabián E. Bustamante, 2007 Welcome to Intro. to Computer

More information

CS Prof J.P.Morrison

CS Prof J.P.Morrison CS1061 2018-2019 Prof J.P.Morrison C Programming C is the most popular language worldwide. Everything from microcontrollers to operating systems is written in C flexible and versatile, allowing maximum

More information

Chapter 4. Channel Coding and Error Control

Chapter 4. Channel Coding and Error Control Chapter 4 Channel Coding and Error Control Adapted from class notes by Prof. Leszek T. Lilien, CS, Western Michigan University and Prof. Dharma P. Agrawal & Qing-An Zeng, University of Cincinnati Most

More information

What is a Better Program?

What is a Better Program? 軟體的特性 What is a Better Program? 軟體之所謂軟 因為沒有 硬性 不可變 不可挑戰的規則 好處 : 彈性很大, 山不轉路轉, 沒有標準答案, 正常運作就好 C++ Object Oriented Programming 壞處 : 很多小問題合在一起不斷放大, 到處藏污納垢, 沒有標準答案, 不知道到底對了沒有 解決方法 Pei-yih Ting Coding styles

More information

COMP1917: Computing 1 1. Introduction

COMP1917: Computing 1 1. Introduction COMP1917: Computing 1 1. Introduction Reading: Moffat, Chapter 1. COMP1917 12s2 Introduction 1 Course Web Site http://www.cse.unsw.edu.au/~cs1917/12s2 Please check this Web Site regularly for updated information,

More information

COMP1917: Computing 1 1. Introduction

COMP1917: Computing 1 1. Introduction COMP1917: Computing 1 1. Introduction Reading: Moffat, Chapter 1. COMP1917 15s2 Introduction 1 Course Web Site http://www.cse.unsw.edu.au/~cs1917/15s2 Please check this Web Site regularly for updated information,

More information

Introduction to Computer Systems

Introduction to Computer Systems Introduction to Computer Systems Today: Welcome to EECS 213 Lecture topics and assignments Next time: Bits & bytes and some Boolean algebra Fabián E. Bustamante, Spring 2010 Welcome to Intro. to Computer

More information

臺北巿立大學 104 學年度研究所碩士班入學考試試題

臺北巿立大學 104 學年度研究所碩士班入學考試試題 臺北巿立大學 104 學年度研究所碩士班入學考試試題 班別 : 資訊科學系碩士班 ( 資訊科學組 ) 科目 : 計算機概論 ( 含程式設計 ) 考試時間 :90 分鐘 08:30-10:00 總分 :100 分 注意 : 不必抄題, 作答時請將試題題號及答案依照順序寫在答卷上 ; 限用藍色或黑色筆作答, 使用其他顏色或鉛筆作答者, 所考科目以零分計算 ( 於本試題紙上作答者, 不予計分 ) 一 單選題

More information

RENESAS BLE 實作課程 Jack Chen Victron Technology CO., LTD 2015 Renesas Electronics Corporation. All rights reserved.

RENESAS BLE 實作課程 Jack Chen Victron Technology CO., LTD 2015 Renesas Electronics Corporation. All rights reserved. RENESAS BLE 實作課程 2016-01-21 Jack Chen Jack.chen@victron.com.tw Victron Technology CO., LTD AGENDA CS+ & Renesas Flash Programmer 安裝 3 Renesas Flash Programmer 燒錄介紹 6 CS+ 介面介紹 11 CS+ 開啟 Project & 使用教學 14

More information

Oxford isolution. 下載及安裝指南 Download and Installation Guide

Oxford isolution. 下載及安裝指南 Download and Installation Guide Oxford isolution 下載及安裝指南 Download and Installation Guide 系統要求 個人電腦 Microsoft Windows 10 (Mobile 除外 ) Microsoft Windows 8 (RT 除外 ) 或 Microsoft Windows 7 (SP1 或更新版本 ) ( 網上下載 : http://eresources.oupchina.com.hk/oxfordisolution/download/index.html)

More information

1. Introduction. Course Web Site. COMP1917: Computing 1. Textbook. Occupational Health and Safety (OHS)

1. Introduction. Course Web Site. COMP1917: Computing 1. Textbook. Occupational Health and Safety (OHS) COMP1917 14s2 Introduction 1 COMP1917: Computing 1 1. Introduction Reading: Moffat, Chapter 1. Course Web Site http://www.cse.unsw.edu.au/~cs1917/14s2 Please check this Web Site regularly for updated information,

More information

外薦交換生線上申請系統操作說明 Instruction on Exchange Student Online Application System. [ 中文版 ] [English Version]

外薦交換生線上申請系統操作說明 Instruction on Exchange Student Online Application System. [ 中文版 ] [English Version] 外薦交換生線上申請系統操作說明 Instruction on Exchange Student Online Application System [ 中文版 ] [English Version] 線上申請流程說明 申請系統網址 : http://schwebap.nccu.edu.tw/zeweb/exgstdapply/ 1. 建立新帳號 : 請輸入姓名 生日 email 做為未來登入系統用

More information

BITG 1113: Introduction To Computers And Programming Language LECTURE 1 LECTURE 1 1

BITG 1113: Introduction To Computers And Programming Language LECTURE 1 LECTURE 1 1 BITG 1113: Introduction To Computers And Programming Language LECTURE 1 LECTURE 1 1 Learning Outcomes At the end of this lecture, you should be able to: tell the purpose of computer programs. describe

More information

Software Project. Lecturers: Ran Caneti, Gideon Dror Teaching assistants: Nathan Manor, Ben Riva

Software Project. Lecturers: Ran Caneti, Gideon Dror Teaching assistants: Nathan Manor, Ben Riva Software Project Lecturers: Ran Caneti, Gideon Dror Teaching assistants: Nathan Manor, Ben Riva Emails: (canetti/benriva)@post.tau.ac.il nathan.manor@gmail.com gideon@mta.ac.il http://www.cs.tau.ac.il/~roded/courses/soft-project10.html

More information

Chapter 1 Introduction to Computers The Internet and the World Wide Web. Objectives. 1.1 Introduction

Chapter 1 Introduction to Computers The Internet and the World Wide Web. Objectives. 1.1 Introduction Chapter 1 Introduction to Computers The Internet and the World Wide Web 1 Chapter 1 Introduction to Computers The Internet and the World Wide Web 2 Outline 1.1 Introduction 1.2 What Is a Computer? 1.3

More information

2009 OB Workshop: Structural Equation Modeling. Changya Hu, Ph.D. NCCU 2009/07/ /07/03

2009 OB Workshop: Structural Equation Modeling. Changya Hu, Ph.D. NCCU 2009/07/ /07/03 Amos Introduction 2009 OB Workshop: Structural Equation Modeling Changya Hu, Ph.D. NCCU 2009/07/02- 2 Contents Amos Basic Functions Observed Variable Path Analysis Confirmatory Factor Analysis Full Model

More information

Java 程式設計基礎班 (7) 莊坤達台大電信所網路資料庫研究室. Java I/O. Class 7 1. Class 7 2

Java 程式設計基礎班 (7) 莊坤達台大電信所網路資料庫研究室. Java I/O.   Class 7 1. Class 7 2 Java 程式設計基礎班 (7) 莊坤達台大電信所網路資料庫研究室 Email: doug@arbor.ee.ntu.edu.tw Class 7 1 回顧 Java I/O Class 7 2 Java Data Structure 動態資料結構 Grow and shrink at execution time Several types Linked lists Stacks Queues Binary

More information

David M. Kroenke and David J. Auer Database Processing Fundamentals, Design, and Implementation

David M. Kroenke and David J. Auer Database Processing Fundamentals, Design, and Implementation David M. Kroenke and David J. Auer Database Processing Fundamentals, Design, and Implementation Chapter Six: Transforming Data Models into Database Designs 6-1 Chapter Objectives To understand how to transform

More information

Chapter 4 (Part IV) The Processor: Datapath and Control (Parallelism and ILP)

Chapter 4 (Part IV) The Processor: Datapath and Control (Parallelism and ILP) Chapter 4 (Part IV) The Processor: Datapath and Control (Parallelism and ILP) 陳瑞奇 (J.C. Chen) 亞洲大學資訊工程學系 Adapted from class notes by Prof. M.J. Irwin, PSU and Prof. D. Patterson, UCB 4.10 Instruction-Level

More information

Introduction to the C-Language and Programming Environment

Introduction to the C-Language and Programming Environment Introduction to the C-Language and Programming Environment Part 1: Basics to get started C Language Tutorial System Programming 251-0053 Winter Semester 2005/06 René Müller, IFW B45.2 SysProg WS05/06 1

More information

0 Introduction: Computer systems and program development

0 Introduction: Computer systems and program development 0 Introduction: Computer systems and program development Outline 1 Introduction 2 What Is a Computer? 3 Computer Organization 4 Evolution of Operating Systems 5 Personal Computing, Distributed Computing

More information

Chris Riesbeck, Fall Introduction to Computer Systems

Chris Riesbeck, Fall Introduction to Computer Systems Chris Riesbeck, Fall 2011 Introduction to Computer Systems Welcome to Intro. to Computer Systems Everything you need to know http://www.cs.northwestern.edu/academics/courses/213/ Instructor: Chris Riesbeck

More information

系統程式設計 Systems Programming

系統程式設計 Systems Programming 系統程式設計 Systems Programming 鄭卜壬教授臺灣大學資訊工程系 Tei-Wei Kuo, Chi-Sheng Shih, Hao-Hua Chu, and Pu-Jen Cheng 2008 Who am I?! Pu-Jen Cheng ( 鄭卜壬 )! Research Interests:! Information Retrieval! Web Knowledge Discovery!

More information

introduction week 1 Ritsumeikan University College of Information Science and Engineering Ian Piumarta 1 / 20 imperative programming about the course

introduction week 1 Ritsumeikan University College of Information Science and Engineering Ian Piumarta 1 / 20 imperative programming about the course week 1 introduction Ritsumeikan University College of Information Science and Engineering Ian Piumarta 1 / 20 class format 30 minutes (give or take a few) presentation 60 minutes (give or take a few) practice

More information

Java 程式設計基礎班 (7) 劉根豪台大電機所網路資料庫研究室. Java I/O. Class 7 1. Class 7

Java 程式設計基礎班 (7) 劉根豪台大電機所網路資料庫研究室. Java I/O.   Class 7 1. Class 7 Java 程式設計基礎班 (7) 劉根豪台大電機所網路資料庫研究室 Email: kenliu@arbor.ee.ntu.edu.tw 1 回顧 Java I/O 2 1 Java Data Structure 動態資料結構 執行的時候可以動態變大或縮小 類型 Linked lists Stacks Queues Binary trees 3 自我參考類別 (self-referential classes)

More information

Chapter 7. Digital Arithmetic and Arithmetic Circuits. Signed/Unsigned Binary Numbers

Chapter 7. Digital Arithmetic and Arithmetic Circuits. Signed/Unsigned Binary Numbers Chapter 7 Digital Arithmetic and Arithmetic Circuits Signed/Unsigned Binary Numbers Signed Binary Number: A binary number of fixed length whose sign (+/ ) is represented by one bit (usually MSB) and its

More information

8/16/12. Computer Organization. Architecture. Computer Organization. Computer Basics

8/16/12. Computer Organization. Architecture. Computer Organization. Computer Basics Computer Organization Computer Basics TOPICS Computer Organization Data Representation Program Execution Computer Languages 1 2 Architecture Computer Organization n central-processing unit n performs the

More information

Computer Architecture 2/26/01 Lecture #

Computer Architecture 2/26/01 Lecture # Computer Architecture 2/26/01 Lecture #9 16.070 On a previous lecture, we discussed the software development process and in particular, the development of a software architecture Recall the output of the

More information

CS 261 Fall C Introduction. Variables, Memory Model, Pointers, and Debugging. Mike Lam, Professor

CS 261 Fall C Introduction. Variables, Memory Model, Pointers, and Debugging. Mike Lam, Professor CS 261 Fall 2017 Mike Lam, Professor C Introduction Variables, Memory Model, Pointers, and Debugging The C Language Systems language originally developed for Unix Imperative, compiled language with static

More information

A software view. Computer Systems. The Compilation system. How it works. 1. Preprocesser. 1. Preprocessor (cpp)

A software view. Computer Systems. The Compilation system. How it works. 1. Preprocesser. 1. Preprocessor (cpp) A software view User Interface Computer Systems MTSU CSCI 3240 Spring 2016 Dr. Hyrum D. Carroll Materials from CMU and Dr. Butler How it works hello.c #include int main() { printf( hello, world\n

More information

Chapter 1 Introduction to Computers and C++ Programming

Chapter 1 Introduction to Computers and C++ Programming Chapter 1 Introduction to Computers and C++ Programming 1 Outline 1.1 Introduction 1.2 What Is a Computer? 1.3 Computer Organization 1.4 Evolution of Operating Systems 1.5 Personal Computing, Distributed

More information

Password Protection 此篇文章說明如何在程式中加入密碼保護的機制, 當程式開啟, 使用者必須先輸入使用者帳號及密碼, 若是合法使用者才能進入應用程式

Password Protection 此篇文章說明如何在程式中加入密碼保護的機制, 當程式開啟, 使用者必須先輸入使用者帳號及密碼, 若是合法使用者才能進入應用程式 Password Protection 此篇文章說明如何在程式中加入密碼保護的機制, 當程式開啟, 使用者必須先輸入使用者帳號及密碼, 若是合法使用者才能進入應用程式 Step 1. 使用 Visual C++ 6.0 產生一個 MFC Application 1) Project name: PasswordProtection 2) Project type: MFC AppWizard(exe)

More information

Chapter 1 INTRODUCTION

Chapter 1 INTRODUCTION Chapter 1 INTRODUCTION A digital computer system consists of hardware and software: The hardware consists of the physical components of the system. The software is the collection of programs that a computer

More information

System Programming. System Software: An Introduction to Systems Programming. Leland L. Beck 3rd Edition Addison-Wesley, 1997

System Programming. System Software: An Introduction to Systems Programming. Leland L. Beck 3rd Edition Addison-Wesley, 1997 System Programming System Software: An Introduction to Systems Programming Leland L. Beck 3rd Edition Addison-Wesley, 1997 1 http://web.thu.edu.tw/ctyang/ 2 http://hpc.csie.thu.edu.tw/ 3 Score List Participation:

More information

Twin API Guide. How to use Twin

Twin API Guide. How to use Twin Twin API Guide How to use Twin 1 目錄 一 Cycle Job------------------------------------------------------------------------------------P3 二 Twin Action Table-----------------------------------------------------------------------P4-5

More information

Computer Basics 1/24/13. Computer Organization. Computer systems consist of hardware and software.

Computer Basics 1/24/13. Computer Organization. Computer systems consist of hardware and software. Hardware and Software Computer Basics TOPICS Computer Organization Data Representation Program Execution Computer Languages Computer systems consist of hardware and software. Hardware includes the tangible

More information

Invitation to Computer Science 5 th Edition. Chapter 8 Information Security

Invitation to Computer Science 5 th Edition. Chapter 8 Information Security Invitation to Computer Science 5 th Edition Chapter 8 Information Security CIA Triad of Information Security Ensuring that data can be modified only by appropriate mechanisms Ensuring that data is protected

More information

Unit 1: Introduction to Programming. Saurabh Khatri Lecturer Department of Computer Technology VIT, Pune

Unit 1: Introduction to Programming. Saurabh Khatri Lecturer Department of Computer Technology VIT, Pune Unit 1: Introduction to Programming Saurabh Khatri Lecturer Department of Computer Technology VIT, Pune Syllabus Unit 1: Introduction to Programming Unit 2: Flow of Control and Functions Unit 3: Arrays

More information

LECTURE/ STUDY NOTES ON C

LECTURE/ STUDY NOTES ON C LECTURE/ STUDY NOTES ON C PART I (Overview of C Programming) Introduction of C language History of C Importance of C Demerits of C Basic Structure of C Working steps of C compiler Source Code Object Code

More information

CSC180: Lecture 2. Wael Aboulsaadat.

CSC180: Lecture 2. Wael Aboulsaadat. CSC180: Lecture 2 Wael Aboulsaadat wael@cs.toronto.edu http://portal.utoronto.ca/ Acknowledgement: These slides are partially based on the slides supplied with Prof. Savitch book: Problem Solving with

More information

Unit. Programming Fundamentals. School of Science and Technology INTRODUCTION

Unit. Programming Fundamentals. School of Science and Technology INTRODUCTION INTRODUCTION Programming Fundamentals Unit 1 In order to communicate with each other, we use natural languages like Bengali, English, Hindi, Urdu, French, Gujarati etc. We have different language around

More information

利用數據與軟體瞭解 讀者行為使用分析與服務平台選項

利用數據與軟體瞭解 讀者行為使用分析與服務平台選項 By using the data and software analysis to study the user experience & the option for the service platform in library field. 利用數據與軟體瞭解 讀者行為使用分析與服務平台選項 周頡 Jeremy Chou EBSCO Information Services Sales Director

More information

Operating System Labs. Yuanbin Wu

Operating System Labs. Yuanbin Wu Operating System Labs Yuanbin Wu cs@ecnu Operating System Labs Introduction to Unix (*nix) Course Overview Operating System Labs Introduction to Unix (*nix) Course Overview Unix / *nix What A family of

More information

黃河凱. Kaiser Huang 巨匠電腦北區 / 新竹認證中心認證講師國立新竹教育大學數位學習科技研究所在職生微軟原廠認證講師 MCT

黃河凱. Kaiser Huang 巨匠電腦北區 / 新竹認證中心認證講師國立新竹教育大學數位學習科技研究所在職生微軟原廠認證講師 MCT 黃河凱 Kaiser Huang 巨匠電腦北區 / 新竹認證中心認證講師國立新竹教育大學數位學習科技研究所在職生微軟原廠認證講師 MCT 2007-2014 微軟嵌入式系統 TTT 教育認證講師 kai168@gmail.com. MCT, MCITP-SA/EA, MCTS-WS2008/CE6/XPe, LPIC 第一堂 : 系統安裝與升級設定的簡介 全新式安裝的步驟與方法 從 DVD 或 USB

More information

C Introduction. Comparison w/ Java, Memory Model, and Pointers

C Introduction. Comparison w/ Java, Memory Model, and Pointers CS 261 Fall 2018 Mike Lam, Professor C Introduction Comparison w/ Java, Memory Model, and Pointers Please go to socrative.com on your phone or laptop, choose student login and join room LAMJMU The C Language

More information

Introduction Presentation A

Introduction Presentation A CSE 2421/5042: Systems I Low-Level Programming and Computer Organization Introduction Presentation A Read carefully: Bryant Chapter 1 Study: Reek Chapter 2 Skim: Reek Chapter 1 08/22/2018 Gojko Babić Some

More information

Course Information and Introduction

Course Information and Introduction August 22, 2017 Course Information 1 Instructors : Email : arash.rafiey@indstate.edu Office : Root Hall A-127 Office Hours : Tuesdays 11:30 pm 12:30 pm. Root Hall, A127. 2 Course Home Page : http://cs.indstate.edu/~arash/cs256.html

More information

1.The First Instrument known in the history of computers was. a) Pascal s adding machine b) Napier s bones c) Abacus d) Analytical Engine

1.The First Instrument known in the history of computers was. a) Pascal s adding machine b) Napier s bones c) Abacus d) Analytical Engine Quiz Questions 1.The First Instrument known in the history of computers was. a) Pascal s adding machine b) Napier s bones c) Abacus d) Analytical Engine 5/1/2006 Computer Programming TA 103 BE I year 2

More information

CS 61C: Great Ideas in Computer Architecture Lecture 2: Introduction to C, Part I

CS 61C: Great Ideas in Computer Architecture Lecture 2: Introduction to C, Part I CS 61C: Great Ideas in Computer Architecture Lecture 2: Introduction to C, Part I Instructors: Vladimir Stojanovic & Nicholas Weaver http://inst.eecs.berkeley.edu/~cs61c/ 1 Agenda Everything is a Number

More information

CSCI 2132 Software Development. Lecture 2: Introduction to UNIX and Unix-like Operating Systems

CSCI 2132 Software Development. Lecture 2: Introduction to UNIX and Unix-like Operating Systems CSCI 2132 Software Development Lecture 2: Introduction to UNIX and Unix-like Operating Systems Instructor: Vlado Keselj Faculty of Computer Science Dalhousie University 7-Sep-2018 (2) CSCI 2132 1 Previous

More information

Computers in Engineering COMP 208. Computer Structure. Computer Architecture. Computer Structure Michael A. Hawker

Computers in Engineering COMP 208. Computer Structure. Computer Architecture. Computer Structure Michael A. Hawker Computers in Engineering COMP 208 Computer Structure Michael A. Hawker Computer Structure We will briefly look at the structure of a modern computer That will help us understand some of the concepts that

More information

Notes By: Shailesh Bdr. Pandey, TA, Computer Engineering Department, Nepal Engineering College

Notes By: Shailesh Bdr. Pandey, TA, Computer Engineering Department, Nepal Engineering College Preparing to Program You should take certain steps when you're solving a problem. First, you must define the problem. If you don't know what the problem is, you can't find a solution! Once you know what

More information

打造新世代企業資料中心 Windows Server 2016 重裝登場. 馮立偉 Hybrid Cloud Lead Microsoft Taiwan

打造新世代企業資料中心 Windows Server 2016 重裝登場. 馮立偉 Hybrid Cloud Lead Microsoft Taiwan 打造新世代企業資料中心 Windows Server 2016 重裝登場 馮立偉 Hybrid Cloud Lead Microsoft Taiwan www.20yearsofwindowsserver.com Windows Server 2016 現今攻擊時程 第一個主機被滲透 網域管理者帳號被破解 攻擊者被發現 24 48 小時 超過 200 天 ( 每個產業不同 ) 攻擊目標及方向

More information

Elements of Computers and Programming Dr. William C. Bulko. What is a Computer?

Elements of Computers and Programming Dr. William C. Bulko. What is a Computer? Elements of Computers and Programming Dr. William C. Bulko What is a Computer? 2017 What is a Computer? A typical computer consists of: a CPU memory a hard disk a monitor and one or more communication

More information

U-oriented Industrial Safety Monitoring Module Development Research

U-oriented Industrial Safety Monitoring Module Development Research U-oriented Industrial Safety Monitoring Module Development Research 1 U-oriented Industrial Safety Monitoring Module Development Research Chia-Ping Huang ABSTRACT This paper aims to provide conventional

More information

Computer Basics 1/6/16. Computer Organization. Computer systems consist of hardware and software.

Computer Basics 1/6/16. Computer Organization. Computer systems consist of hardware and software. Hardware and Software Computer Basics TOPICS Computer Organization Data Representation Program Execution Computer Languages Computer systems consist of hardware and software. Hardware includes the tangible

More information

BTC, EMPREX Wireless Keybaord +Mouse + USB dongle. 6309URF III Quick Installation Guide

BTC, EMPREX Wireless Keybaord +Mouse + USB dongle. 6309URF III Quick Installation Guide BTC, EMPREX 6309URF III Quick Installation Guide Hardware Installation 1. Plug the dongle receiver connector into your available USB port on PC. 2. Make sure the batteries of the keyboard and mouse are

More information

C LANGUAGE AND ITS DIFFERENT TYPES OF FUNCTIONS

C LANGUAGE AND ITS DIFFERENT TYPES OF FUNCTIONS C LANGUAGE AND ITS DIFFERENT TYPES OF FUNCTIONS Manish Dronacharya College Of Engineering, Maharishi Dayanand University, Gurgaon, Haryana, India III. Abstract- C Language History: The C programming language

More information

3.1 Animation. Rotating Square

3.1 Animation. Rotating Square 3.1 Animation 動畫 1 Rotating Square Consider the four points 圖 3.1 Animate display by rerendering with different values of θ 2 1 事件 (Event) 之種類 Window: resize, expose, iconify Mouse: click one or more buttons

More information

Computer Fundamentals

Computer Fundamentals Computer Fundamentals 1 Draw the block diagram of computer architecture and explain each block. Computer is made up of mainly four components, 1) Central processing unit (CPU) 2) Input section 3) Output

More information

Machine Architecture and Number Systems CMSC104. Von Neumann Machine. Major Computer Components. Schematic Diagram of a Computer. First Computer?

Machine Architecture and Number Systems CMSC104. Von Neumann Machine. Major Computer Components. Schematic Diagram of a Computer. First Computer? CMSC104 Lecture 2 Remember to report to the lab on Wednesday Topics Machine Architecture and Number Systems Major Computer Components Bits, Bytes, and Words The Decimal Number System The Binary Number

More information

Laboratory 2: Programming Basics and Variables. Lecture notes: 1. A quick review of hello_comment.c 2. Some useful information

Laboratory 2: Programming Basics and Variables. Lecture notes: 1. A quick review of hello_comment.c 2. Some useful information Laboratory 2: Programming Basics and Variables Lecture notes: 1. A quick review of hello_comment.c 2. Some useful information 3. Comment: a. name your program with extension.c b. use o option to specify

More information