官术网_书友最值得收藏!

The Hello World example

Since we are done setting up the Raspberry Pi, let's get things rolling by writing our first piece of code in Python. While learning a new programming language, it is customary to get started by printing Hello World on the computer screen. Let's print the following message: I am excited to learn Python programming with the Raspberry Pi Zero using Python.

In this book, we will learn Python using the Integrated Development and Learning Environment (IDLE) tool. We chose IDLE for the following reasons:

  • The tool is installed and shipped as a package in the Raspbian OS image. No additional installation is required.
  • It is equipped with an interactive tool that enables performing checks on a piece of code or a specific feature of the Python language.
  • It comes with a text editor that enables writing code according to the conventions of the Python programming language. The text editor provides a color code for different elements of a Python script. This helps in writing a Python script with relative ease.
  • The tool enables a step-by-step execution of any code sample and identify problems in it.
主站蜘蛛池模板: 佛坪县| 丹凤县| 汉中市| 元氏县| 三明市| 斗六市| 潜江市| 吕梁市| 青铜峡市| 巩留县| 兰溪市| 柳河县| 资兴市| 库车县| 龙南县| 弥渡县| 郎溪县| 理塘县| 平山县| 同仁县| 太原市| 漳平市| 孝感市| 泸西县| 阿坝| 怀远县| 桂平市| 米脂县| 长岛县| 习水县| 东方市| 五家渠市| 拉孜县| 汝州市| 屏边| 虹口区| 石楼县| 桂林市| 监利县| 泾阳县| 高陵县|