Python 3.6.5 ドキュメント 検索

phrase: max: clip:
target: order:
Results of 1 - 10 of about 76 for result (0.026 sec.)
18.5.3. タスクとコルーチン — Python 3.6.5 ドキュメント 16831
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ ... True を返す) と呼びます。 コルーチンができること: result = await future or result = yield from future -- su ... ntil the future is done, then returns the future's result, or raises an exception, which will be propagated. ... erything said about futures also applies to tasks. result = await coroutine or result = yield from coroutine ... -- wait for another coroutine to produce a result (or raise an exception, which will be propagated). ...
https://man.plustar.jp/python/library/asyncio-task.html - [similar]
17.4. concurrent.futures -- 並列タスク実行 — Python 3.6.5 ドキュメント 9586
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ ... tor . submit ( pow , 323 , 1235 ) print ( future . result ()) map ( func , *iterables , timeout=None , chunk ... tures.TimeoutError if __next__() is called and the result isn't available after timeout seconds from the ori ... e def wait_on_b (): time . sleep ( 5 ) print ( b . result ()) # b will never complete because it is waiting ... 5 def wait_on_a (): time . sleep ( 5 ) print ( a . result ()) # a will never complete because it is waiting ...
https://man.plustar.jp/python/library/concurrent.futures.html - [similar]
プログラミング FAQ — Python 3.6.5 ドキュメント 9198
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python よくある質問 ... urn _cache [( arg1 , arg2 )] # Calculate the value result = ... expensive computation ... _cache [( arg1 , a ... rg2 )] = result # Store result in the cache return result デフォル ... トされたスコープを使うと: def linear ( a , b ): def result ( x ): return a * x + b return result また、呼び出 ... s = [] for s in my_strings : chunks . append ( s ) result = '' . join ( chunks ) (他の割と効率的なイディオム ...
https://man.plustar.jp/python/faq/programming.html - [similar]
3. Defining Extension Types: Assorted Topics — Python 3.6.5 ドキュメント 9101
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python インタプリタ ... yObject * self = ( MyObject * ) obj ; PyObject * cbresult ; if ( self -> my_callback != NULL ) { PyObject * ... ( & err_type , & err_value , & err_traceback ); cbresult = PyObject_CallObject ( self -> my_callback , NULL ... ); if ( cbresult == NULL ) PyErr_WriteUnraisable ( self -> my_callb ... ack ); else Py_DECREF ( cbresult ); /* This restores the saved exception state */ P ...
https://man.plustar.jp/python/extending/newtypes.html - [similar]
18.5.9. asyncio での開発 — Python 3.6.5 ドキュメント 8616
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ ... ます。 Future がキャンセルされた場合、 Future の set_result() または set_exception() メソッドは呼び出さないでく ... いてください。 if not fut . cancelled (): fut . set_result ( 'done' ) AbstractEventLoop.call_soon() で、Futur ... e の set_result() メソッドまたは set_exception() メソッドの呼び出し ... . run_coroutine_threadsafe ( coro_func (), loop ) result = future . result ( timeout ) # Wait for the resul ...
https://man.plustar.jp/python/library/asyncio-dev.html - [similar]
1. C や C++ による Python の拡張 — Python 3.6.5 ドキュメント 8519
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python インタプリタ ... PyObject * dummy , PyObject * args ) { PyObject * result = NULL ; PyObject * temp ; if ( PyArg_ParseTuple ( ... erplate to return "None" */ Py_INCREF ( Py_None ); result = Py_None ; } return result ; } この関数は METH_VA ... 示します: int arg ; PyObject * arglist ; PyObject * result ; ... arg = 123 ; ... /* Time to call the callback ... */ arglist = Py_BuildValue ( "(i)" , arg ); result = PyObject_CallObject ( my_callback , arglist ); P ...
https://man.plustar.jp/python/extending/extending.html - [similar]
Python 3 への拡張モジュール移植 — Python 3.6.5 ドキュメント 8325
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python HOWTO » Pyth ... t * self , PyObject * args ) { PyObject * name , * result ; if ( ! PyArg_ParseTuple ( args , "U:say_hello" , ... & name )) return NULL ; result = PyUnicode_FromFormat ( "Hello, %S!" , name ); re ... turn result ; } /* just a forward */ static char * do_encode ( ... , PyObject * args ) { char * encoded ; PyObject * result , * myobj ; if ( ! PyArg_ParseTuple ( args , "O:en ...
https://man.plustar.jp/python/howto/cporting.html - [similar]
29.6. contextlib --- with 文コンテキスト用ユーティリティ — Python 3.6.5 ドキュ... 8034
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python 標準ライブラ ... ようなコードになります: cleanup_needed = True try : result = perform_operation () if result : cleanup_needed ... as stack : stack . callback ( cleanup_resources ) result = perform_operation () if result : stack . pop_all ... all () with Callback ( cleanup_resources ) as cb : result = perform_operation () if result : cb . cancel () ... : @stack . callback def cleanup_resources (): ... result = perform_operation () if result : stack . pop_all ...
https://man.plustar.jp/python/library/contextlib.html - [similar]
4. その他の制御フローツール — Python 3.6.5 ドキュメント 7840
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » Python チュートリア ... st containing the Fibonacci series up to n.""" ... result = [] ... a , b = 0 , 1 ... while a < n : ... resul ... ( a ) # see below ... a , b = b , a + b ... return result ... >>> f100 = fib2 ( 100 ) # call it >>> f100 # w ... rite the result [0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89] この例は ... ります。関数が終了したときにも None が返ります。 文 result.append(a) では、リストオブジェクト result の メソッ ...
https://man.plustar.jp/python/tutorial/controlflow.html - [similar]
What's New In Python 3.6 — Python 3.6.5 ドキュメント 7743
ナビゲーション 索引 モジュール | 次へ | 前へ | Python » 3.6.5 ドキュメント » What's New in Pytho ... >> value = decimal . Decimal ( "12.34567" ) >>> f "result: { value :{ width } . { precision }} " # nested fi ... elds 'result: 12.35' 参考 PEP 498 -- Literal String Interpolati ... レータ式内での async for の使用がサポートされました: result = [ i async for i in aiter () if i % 2 ] 加えて、 ... await 式が全ての内包表記でサポートされました: result = [ await fun () for fun in funcs if await conditi ...
https://man.plustar.jp/python/whatsnew/3.6.html - [similar]
PREV 1 2 3 4 5 6 7 8 NEXT