Python Programming for Beginners: Lesson 6 - Float Type

preview_player
Показать описание
In this lesson, I explain the float variable type: what it is, and how to use them in code. The float type is used in many applications to store numbers that have a decimal component. You may think that floats are simple but I will show you things you may not know about them. I'll also introduce you to complex numbers.

Slides and Code
Рекомендации по теме
Комментарии
Автор

Hi Bryan,

I like your tutorials on Python and Databricks, as I currently need to learn them for my new job. I am/used to be a .NET developer.
Keep at it, this is really great work. Also gonna buy your book :)

Slight correction for the scientific notation of numbers:

2.1e+21 is equal to 2.1 * 10**21. That is, times 10 to the power of 21. It's not the number itself to the power of 21. Essentially, this shifts the decimal point 21 places to the right. And in case of a negative exponent, to the left. Further, this representation should be normalized (the number in the video is), that means there mustn't be a zero in front of the decimal point. This pins down the exponent to 21, otherwise it could be 21 or 22 (2.1e+21 or 0.21e+22).

For the use cases of complex numbers: Signal processing (audio/video) with the Fast Fourier Transform). The reason the Fourier transform is fast is because of complex numbers (very simply put)

IRofledTheLL