Raspberry Pi: Programming For Beginners (Raspberry Pi 3, Set Up, Raspberry Projects, Programming, Tips, Tricks, Step-by-Step, Problems, Solutions, Start Own Project) by Richard Dorsey

Raspberry Pi: Programming For Beginners (Raspberry Pi 3, Set Up, Raspberry Projects, Programming, Tips, Tricks, Step-by-Step, Problems, Solutions, Start Own Project) by Richard Dorsey

Author:Richard Dorsey [Dorsey, Richard]
Language: eng
Format: azw3
Published: 2017-05-17T04:00:00+00:00


float decimal numbers 3.14

integer whole numbers 7

string character sequences “Skate park”

boolean true/false True

There are more, but these are the biggest ones.

Python Math

Guess what computers do? They compute. And they’re very, very, very good at it. It’s no wonder, then, that programming languages are literally made to do math. There’s not much to show here, I’ll be brief:

numberOfCats = 4 + 3 # numberOfCats would be 7

numberOfDogs = 8 / 2 # numberOfDogs would be 4

numberOfHamsters = 3^2 # numberOfHamsters would be 9

For the record, the thing with the hash mark is a comment. These are ignored by the code. When you enter a hash (#), you are telling the compiler - the thing which reads and runs your code - to ignore anything that comes after the hash mark on that line. Simple concept, sure, but worth covering.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.