Python 3.6.5 ドキュメント 検索
Results of 71 - 80 of about 213 for return (0.133 sec.)
- 関数型プログラミング HOWTO — Python 3.6.5 ドキュメント 5219
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python HOWTO » 関数
...
' , 'line 2 \n ' , ... ] # Generator expression -- returns iterator stripped_iter = ( line . strip () for li...
ne in line_list ) # List comprehension -- returns list stripped_list = [ line . strip () for line i...
を作るプライベートな名前空間ができますね。その関数が return 文まで来ると、ローカル変数が破壊されてから、返り値...
ます。上の例で yield を実行したとき、 ジェネレータは return 文のようにして i の値を出力します。 yield と retur...
- https://man.plustar.jp/python/howto/functional.html - [similar]
- 29.6. contextlib --- with 文コンテキスト用ユーティリティ — Python 3.6.5 ドキュ... 5219
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ
...
mentation for object.__enter__() is provided which returns self while object.__exit__() is an abstract metho...
d which by default returns None . See also the definition of コンテキストマネ...
or ): def __enter__ ( self ): print ( 'Starting' ) return self def __exit__ ( self , * exc ): print ( 'Finis...
hing' ) return False >>> @mycontext () ... def function (): ... p...
- https://man.plustar.jp/python/library/contextlib.html - [similar]
- 19.1.7. email.contentmanager: MIME 内容の管理 — Python 3.6.5 ドキュメント 5219
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ
...
raph), call it, passing through all arguments, and return the result of the call. The expectation is that th...
e handler will extract the payload from msg and return an object that encodes information about the extra...
d to the base API: get_content on a text part will return a unicode string without the application needing t...
tmanager. get_content ( msg , errors='replace' ) ¶ Return the payload of the part as either a string (for te...
- https://man.plustar.jp/python/library/email.contentmanager.html - [similar]
- 6.2. re --- 正規表現操作 — Python 3.6.5 ドキュメント 5219
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ
...
した。 re. findall ( pattern , string , flags=0 ) ¶ Return all non-overlapping matches of pattern in string ,...
e string is scanned left-to-right, and matches are returned in the order found. If one or more groups are pr...
esent in the pattern, return a list of groups; this will be a list of tuples if...
in a next match, so findall(r'^|\w+', 'two words') returns ['', 'wo', 'words'] (note missed "t"). This is ch...
- https://man.plustar.jp/python/library/re.html - [similar]
- 9.7. statistics --- 数理統計関数 — Python 3.6.5 ドキュメント 5219
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ
...
のは見やすさのためです。 statistics. mean ( data ) ¶ Return the sample arithmetic mean of data which can be a...
とと等価です。 statistics. harmonic_mean ( data ) ¶ Return the harmonic mean of data , a sequence or iterator...
バージョン 3.6 で追加. statistics. median ( data ) ¶ Return the median (middle value) of numeric data, using t...
median_grouped() statistics. median_low ( data ) ¶ Return the low median of numeric data. If data is empty,...
- https://man.plustar.jp/python/library/statistics.html - [similar]
- バッファプロトコル (buffer Protocol) — Python 3.6.5 ドキュメント 5177
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python/C API リファ
...
fset: (char *)buf - mem """ if offset % itemsize : return False if offset < 0 or offset + itemsize > memlen...
: return False if any ( v % itemsize for v in strides ): re...
turn False if ndim <= 0 : return ndim == 0 and not shape and not strides if 0 in sh...
ape : return True imin = sum ( strides [ j ] * ( shape [ j ] -...
- https://man.plustar.jp/python/c-api/buffer.html - [similar]
- プログラミング FAQ — Python 3.6.5 ドキュメント 5177
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python よくある質問
...
s ... compute something ... mydict [ key ] = value return mydict 初めてこの関数を呼び出した時、 mydict には一...
rg2 , _cache = {}): if ( arg1 , arg2 ) in _cache : return _cache [( arg1 , arg2 )] # Calculate the value res...
rg1 , arg2 )] = result # Store result in the cache return result デフォルト値の代わりに、辞書を含むグローバル...
re local names b = b + 1 # assigned to new objects return a , b # return new values x , y = 'old-value' , 99...
- https://man.plustar.jp/python/faq/programming.html - [similar]
- 24.2. cmd --- 行指向のコマンドインタープリタのサポート — Python 3.6.5 ドキュメ... 5177
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ
...
このメソッドは postcmd() メソッドが真を返したときに return します。 postcmd() に対する stop 引数は、このコマン...
to ( * parse ( arg )) def do_home ( self , arg ): 'Return turtle to the home position: HOME' home () def do_...
def do_reset ( self , arg ): 'Clear the screen and return turtle to center: RESET' reset () def do_bye ( sel...
ank you for using Turtle' ) self . close () bye () return True # ----- record and playback ----- def do_reco...
- https://man.plustar.jp/python/library/cmd.html - [similar]
- 32.12. dis --- Python バイトコードの逆アセンブラ — Python 3.6.5 ドキュメント 5177
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ
...
以下の関数 myfunc() を考えると def myfunc ( alist ): return len ( alist ) myfunc() の逆アセンブル結果を表示する...
0 (len) 2 LOAD_FAST 0 (alist) 4 CALL_FUNCTION 1 6 RETURN_VALUE ("2" は行番号です)。 32.12.1. バイトコード解...
. opname ) ... LOAD_GLOBAL LOAD_FAST CALL_FUNCTION RETURN_VALUE 32.12.2. 解析関数 ¶ dis モジュールには、以下...
ーションで利用できるようにスタックに残しておきます。 RETURN_VALUE ¶ 関数の呼び出し元へ TOS を返します。 YIELD_...
- https://man.plustar.jp/python/library/dis.html - [similar]
- What's New in Python 2.1 — Python 3.6.5 ドキュメント 5177
- ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » What's New in Pytho
...
定義は動きません: def f (): ... def g ( value ): ... return g ( value - 1 ) + 1 ... 名前 g はローカルの名前空間...
変数を頻繁に見かけます。: def find ( self , name ): "Return list of any entries equal to 'name'" L = filter (...
name = name : x == name , self . list_attribute ) return L 過度な関数型スタイルで書かれた Python コードの可...
e next line is a syntax error exec 'x=2' def g (): return x exec 文を含む 4 行目は文法エラーです。 exec とし...
- https://man.plustar.jp/python/whatsnew/2.1.html - [similar]