3. Data types and variable naming convention in python

preview_player
Показать описание
There are different data types including numeric, string, sequential, mapping, boolean, set, and binary. For these different types we have different variables including integer, float, complex, string, list, tuple, set, dictionary, boolean, byte, bytearray, and memoryview.
Variables can be named with flexibility. Preference is given for short, descriptive names and this video explains when we use camelCase, CapCase, and snake case along with general rules for naming variables, functions, modules, and constants.
Рекомендации по теме
Комментарии
Автор

Well, an int value is far from unlimited, matter of fact in computer science everything is limited and you have to make trade-offs in every situation. Int in C can store a value up to 4 billion (2 billion positive and 2 billion negative) because the default memory allocation for an int is 4 bytes. In python ints and floats allocate more memory for less headache but for that the memory management is worse (trade-off). Float doesn't have multiple floating points. As the name suggests they have only one point which is floating around and because of that floating point inaccuracy can happen. If you cannot make a proper explanation about the most basic variable types don't consider making educational lectures in computer science. Keep on working.

balazsszabo
visit shbcf.ru