Python 的 ord(~)
方法返回所提供的輸入字符串的 Unicode 代碼點。
參數
1. c
| string
要返回其 Unicode 代碼點的字符。
返回值
與輸入字符串對應的 Unicode 代碼點。
例子
基本用法
返回字符串 'Y'
的 Unicode 代碼點:
ord('Y')
89
相關用法
- Python ord()用法及代碼示例
- Python NumPy ones方法用法及代碼示例
- Python os.path.normcase()用法及代碼示例
- Python os.read()用法及代碼示例
- Python os.DirEntry.inode()用法及代碼示例
- Python os.closerange()用法及代碼示例
- Python os.set_blocking()用法及代碼示例
- Python os.pathconf()用法及代碼示例
- Python os.chflags()用法及代碼示例
- Python open()用法及代碼示例
- Python operator.truth()用法及代碼示例
- Python os.WCOREDUMP()用法及代碼示例
- Python os.fork()用法及代碼示例
- Python os.ctermid()用法及代碼示例
- Python os.mkfifo()用法及代碼示例
- Python os.tcsetpgrp()用法及代碼示例
- Python os.path.commonpath()用法及代碼示例
- Python os.path.splitdrive用法及代碼示例
- Python os.mkdir()用法及代碼示例
- Python os.close()用法及代碼示例
- Python os.chroot()用法及代碼示例
- Python os.ttyname()用法及代碼示例
- Python os.path.splitext用法及代碼示例
- Python os.setregid()用法及代碼示例
- Python os.abort()用法及代碼示例
注:本文由純淨天空篩選整理自Arthur Yanagisawa大神的英文原創作品 Python | ord method。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。