Dynamic typing

If you're used to languages such as C++, C# or Java, you'll know that in these languages, variables must be declared before they can be used. Declaring a variable in…

Continue Reading Dynamic typing

Fractions

[latexpage] If you have nightmares from trying to deal with fractions from your school days, Python's Fraction data type may be just what you need. A Fraction is an object…

Continue Reading Fractions

Decimals

We've seen that floats in Python can sometimes be inaccurate due to roundoff error.  One way to correct this is to use Python's Decimal data type. A Decimal variable allows…

Continue Reading Decimals

Integers in Python

[latexpage]We'll start our survey of data types in Python with the most basic type: numbers. If you're used to other programming languages, you might expect only the two most basic…

Continue Reading Integers in Python

Installing Visual Studio for Python

I will use Visual Studio Community as the development environment for writing Python programs. It is available for free from Microsoft's Visual Studio website. It's easiest if you Google 'Visual…

Continue Reading Installing Visual Studio for Python