Pythonプログラマーなら誰もが一度は使ったことがあるimport文。しかし、その裏側にある「モジュール」「パッケージ」「ライブラリ」といった概念や、コードを読みやすく保つための作法まで、深く理解している人は意外と少ないかもしれません。 この記事 ...
Pythonの強力さの源泉は、日付操作のdatetimeや乱数のrandomといった、豊富なライブラリ(モジュール)にあります。これらの機能を使うためには、import文を使って、自分のスクリプトにその機能を読み込む必要があります。 importの方法にはいくつかのパターン ...
No more waiting on slow-loading modules or wasting time on ad hoc workarounds: Python 3.15’s new ‘lazy imports’ mechanism has ...
Once you know how to add and use a Python module, you will greatly extend the capabilities of the language. A Python module is an external class or set of functions that exist outside the main file of ...
Pythonに限らず、多くのプログラミング言語には「関数(Function)」という概念があります。関数は特定の機能を「呼び出す」ために使われます。たとえば今までの回で利用していたprint()も関数のひとつで、()の中に入れた変数や定数を出力するという処理を ...
Python 2. 5以前からある 「turtle」 モジュールが、 Python 2. 6/ 3. 0からパワーアップしています。新しいturtleモジュールを利用すると、 オブジェクト指向アプローチでさまざまなデータの可視化ができます。turtleモジュールはtkinterを利用しただけの単一 ...
There's a not-so-hidden danger when using Python that you need to be prepared to deal with. All modern software development languages are modular, which means developers can break larger sections of ...
米Microsoftは6月30日(現地時間)、「Visual Studio Code」向けの拡張機能「Pylance」を発表した。現在、“Visual Studio Marketplace”から無償でダウンロードできる。 「Pylance」は言語サーバープロトコル(LSP)を使用して「Visual Studio Code」と対話する新しい言語サーバー ...
現在アクセス不可の可能性がある結果が表示されています。
アクセス不可の結果を非表示にする