質問編集履歴
1
PEP257に記載がありました
title
CHANGED
File without changes
|
body
CHANGED
@@ -89,6 +89,16 @@
|
|
89
89
|
|
90
90
|
上記でみてきたように、ライブラリによってdocstringにおける引数の書き方にはいくつかの種類があります。
|
91
91
|
|
92
|
-
Pythonにはdocstringの書き方について書いてある [PEP257](https://www.python.org/dev/peps/pep-0257/) がありますが、そ
|
92
|
+
Pythonにはdocstringの書き方について書いてある [PEP257](https://www.python.org/dev/peps/pep-0257/) がありますが、そこには
|
93
93
|
|
94
|
+
```
|
95
|
+
def complex(real=0.0, imag=0.0):
|
96
|
+
"""Form a complex number.
|
97
|
+
|
98
|
+
Keyword arguments:
|
99
|
+
real -- the real part (default 0.0)
|
100
|
+
imag -- the imaginary part (default 0.0)
|
101
|
+
"""
|
102
|
+
```
|
103
|
+
|
94
|
-
Pythonistaのみなさんはどのように書くべきだと思われますでしょうか。
|
104
|
+
このように書け、と書いてありましたが、Pythonistaのみなさんはどのように書くべきだと思われますでしょうか。
|