ニュース

モジュールの概要: モジュールはPythonの`ModuleType`オブジェクトで、一度インポートすると`sys.modules`にキャッシュされる。 インポートの仕組み: Pythonは`import`時にまず`sys.modules`を確認し、存在しなければ新しいモジュールを読み込んで実行する。 モジュール ...
Pythonの基礎としてモジュール及びパッケージを説明します。一般的な用語の説明は下記の通りです。 パッケージ:複数モジュールがまとめて管理されたディレクトリ ライブラリ:プログラムの再利用や配布が可能な形式にまとめたもの。複数の ...
一度定義した関数は、いろいろなところで再利用したいものです。 本連載では、今までPythonのプログラムを記述したファイル「Pythonスクリプト」を作成してきました(Pythonスクリプトについて詳しくは連載第3回をご覧ください)。関数定義をPython ...
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 ...
Libraries are collections of shared code. They're common in Python, where they're also called "modules," but they're also ...
第9回は、オブジェクト指向のスクリプト言語であるPythonを使ってみましょう。PythonのHello Worldは、リスト1のようにprintを使って記述すればOKです。文字列の最後に改行コードを付ける必要はありません。Pythonの文字列は、Perl等とは違って、シングルクォート ...
翔泳社では、「独習」「徹底入門」「スラスラわかる」「絵で見てわかる」「一年生」などの人気シリーズをはじめ、言語や開発手法、最新技術を解説した書籍を多数手がけています。プロジェクトマネジメントやチームビルティングといった管理職向けの ...
WARNING:opentelemetry.trace:Overriding of current TracerProvider is not allowed WARNING:opentelemetry._logs._internal:Overriding of current LoggerProvider is not allowed WARNING:opentelemetry.metrics.