python中print函數參數解析


print(*values: object,
    sep: Optional[Text]=..., 
    end: Optional[Text]=..., 
    file: Optional[_Writer]=..., 
    flush: bool=...) -> None

參數詳解:

param *values: object
print(value, ..., sep=' ', end='\n', file=sys.stdout, flush=False)
Prints the values to a stream, or to sys.stdout by default.
Optional keyword arguments:
file: a file-like object (stream); defaults to the current sys.stdout.
sep: string inserted between values, default a space.
end: string appended after the last value, default a newline.
flush: whether to forcibly flush the stream.

print的效用:Prints the values to a stream, or to sys.stdout by default.—將值以流的形式輸出,或者使用默認打印在控制台
print函數參數列表:


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM