Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
C 程式語言 I
Search
Nedval
September 23, 2016
Education
120
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
C 程式語言 I
Nedval
September 23, 2016
More Decks by Nedval
See All by Nedval
if else statement
nedval
0
65
軟體測試與驗證—CI & CU
nedval
0
85
SQL Intro
nedval
0
110
Other Decks in Education
See All in Education
HCI and Interaction Design - Lecture 2 - Human-Computer Interaction (1023841ANR)
signer
PRO
0
2k
EL GEOPARQUE MUNDIAL UNESCO VOLCANES DE CALATRAVA: DE LA INVESTIGACIÓN CIENTÍFICA A LA TRANSPOSICIÓN DIDÁCTICA EN EL AULA
juanmartin2026
0
32k
私たちはなんでテストするんだっけ? Ver.東北IT物産展2026 in 会津若松
camel_404
3
220
新型コロナ禍をともに「楽しみながら開いていこう!」 :中門 吉松 会員(2720 Japan O.K.ロータリーEクラブ)卓話 : 2026.10.19.例会・卓話
2720japanoke
0
210
検定資格の価値 ~実はすごいよQC検定~
bunnchinn3
0
260
El Geoparque Mundial UNESCO Volcanes de Calatrava de la Investigación Científica a la Transposición Didáctica en el aula
juanmartin2026
1
32k
Carbohydrates: Classification, Structure & Chemical Properties
pawan_pharm
0
330
FA26 CLU MS Clinical Psychology New Student Orientation
jdbedics
0
180
The Dirty Dozen: 12 gala mistakes you don’t know you’re making
auctria
PRO
0
140
CSS3 and Responsive Web Design - Lecture 5 - Web Technologies (1019888BNR)
signer
PRO
1
3.5k
Requirements Analysis and Prototyping - Lecture 3 - Human-Computer Interaction (1023841ANR)
signer
PRO
0
1.8k
20260908_ターゲットとスコープを決める発表法
masakiokuda
1
140
Featured
See All Featured
世界の人気アプリ100個を分析して見えたペイウォール設計の心得
akihiro_kokubo
PRO
74
43k
The untapped power of vector embeddings
frankvandijk
2
1.9k
Marketing to machines
jonoalderson
1
5.9k
What the history of the web can teach us about the future of AI
inesmontani
PRO
2
740
How to optimise 3,500 product descriptions for ecommerce in one day using ChatGPT
katarinadahlin
PRO
3
3.9k
Agile Leadership in an Agile Organization
kimpetersen
PRO
0
280
ReactJS: Keep Simple. Everything can be a component!
pedronauck
666
130k
Mobile First: as difficult as doing things right
swwweet
225
10k
10 Git Anti Patterns You Should be Aware of
lemiorhan
PRO
659
62k
RailsConf 2023
tenderlove
30
1.6k
We Are The Robots
honzajavorek
0
400
Lightning talk: Run Django tests with GitHub Actions
sabderemane
0
300
Transcript
C 程式語言 by
[email protected]
C 程式語言
C 程式語言 文法(Grammar)
C 程式語言 文法(Grammar) 語法(syntax)
句型 e.g., S + V + O
陳述 (statement)
宣告陳述式 (Declaration Statements)
宣告陳述式 (Declaration Statements) 型態 變數名稱 值 type variable name value
型態 變數名稱 值 type variable name value 讓人容易閱讀的代稱
型態 變數名稱 值 type variable name value 代稱所代表的內容
型態 變數名稱 值 type variable name value 內容的類型
先離題一下 … 聽說最近有部電影很紅
先離題一下 … 聽說最近有部電影很紅 名字是 …
君の名は
your name
your name
your name 讓我們試著把這部電影的名稱用 C 語言表示
your name
your name 名詞
your name 名詞 字串(string)
your name 名詞 字串(string) C 語言中又稱字元陣列
your_name 變數名稱限制: 開頭不能是數字 中間不能空白 … 等 字串(string)
your_name char* 一個變數名稱通常代表兩個特質
your_name char* 空間 值 { 一個變數名稱通常代表兩個特質
your_name char* 空間 值 { 一個變數名稱通常代表兩個特質
your_name char* 這個陳述中,只有宣告了一個代號為 your_name 的空間 裡面可以放字元陣列的值,由於尚未放任何內容進去 因此現在 your_name 裡面沒有任何東西 如同電影「你的名字」一樣
在你進電影院前不知道「你的名字」到底是什麼
your_name char* 假如,我們看完電影了,已經知道名字到底是什麼 我們要怎麼放到 your_name 這個空間呢?
your_name char* ... 假如這是主角的名字 它是字串型態
your_name char* "..." 字串型態的內容應放在雙引號中
your_name char* "..." 至於你的名字到底叫什麼?
your_name char* "..." 就請大家進影院看啦~
your_name char* "..." 現在我們有「型態」「變數名稱」以及「值」了 可是 這樣還不是一個完整的陳述 (statement)
your_name char* "..." = 我們需要加一個「這個」
your_name char* "..." = 「這個」是什麼?
your_name char* "..." = 等於?
your_name char* "..." = 等於? NO!!!
What?
蕭煌奇唱過一首歌
那首歌是這樣唱的 …
眼前的等於不是等於~ 你說的等號是什麼等號?
= 在 C 以及多數程式語言中 一個等號稱為:賦值(assign)
= 在 C 以及多數程式語言中 一個等號稱為:賦值 assign 意即賦予等號左邊的空間擁有右邊的值
= 在 C 以及多數程式語言中 一個等號稱為:賦值 assign 意即賦予等號左邊的空間擁有右邊的值
例句
My name is Jrting
My name is Jrting 變數名稱
My name is Jrting 變數名稱 my_name
My name is Jrting 賦值 my_name
My name is Jrting 賦值 = my_name
My name is Jrting 型態:字串 = my_name
My name is Jrting 型態:字串 char* "" = my_name
My name is Jrting 值 char* "Jrting" = my_name
My name is Jrting char* "Jrting" = my_name
結束了嗎?
還沒~
你忘了一件事…
英文老師說句子的結尾要句點
My name is Jrting. char* my_name = "Jrting" Important !!!
My name is Jrting. char* my_name = "Jrting"; Important !!!
上機練習