or
or
By clicking below, you agree to our terms of service.
New to HackMD? Sign up
Syntax | Example | Reference | |
---|---|---|---|
# Header | Header | 基本排版 | |
- Unordered List |
|
||
1. Ordered List |
|
||
- [ ] Todo List |
|
||
> Blockquote | Blockquote |
||
**Bold font** | Bold font | ||
*Italics font* | Italics font | ||
~~Strikethrough~~ | |||
19^th^ | 19th | ||
H~2~O | H2O | ||
++Inserted text++ | Inserted text | ||
==Marked text== | Marked text | ||
[link text](https:// "title") | Link | ||
 | Image | ||
`Code` | Code |
在筆記中貼入程式碼 | |
```javascript var i = 0; ``` |
|
||
:smile: | ![]() |
Emoji list | |
{%youtube youtube_id %} | Externals | ||
$L^aT_eX$ | LaTeX | ||
:::info This is a alert area. ::: |
This is a alert area. |
On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?
Please give us some advice and help us improve HackMD.
Syncing
xxxxxxxxxx
tags:
python
資料型別
不同情境使用不同資料型別,可以簡化程式撰寫及錯誤發生
int(整數,沒有小數點)
float(浮點數,有小數點)
bool(布林,真/假)
str(字串)
備註: 顯示變數的資料型態
list
練習
請使用者輸入國文、英文、數學成績
顯示最高分數是幾分
請使用者輸入想購買的水果名稱
顯示該商店是否有該水果可出售
fruit = ['香蕉', '鳳梨', '百香果', '釋迦', '梨子']
tuple
set
dict
補充說明
可利用dir()查詢該變數擁有哪些屬性及方法
不同資料型別擁有哪些屬性及方法,之後會在特別介紹
補充說明
中華民國電腦技能基金會 範例試卷
S20200609 來自amos老師的網站。資料型別