Every single day you share tons of data with mostly few American companies (Amazon, Apple [not so much thanks to their business model], Facebook [way too much BECAUSE OF their business model], Instagram [which belongs to Facebook], Google [same business model as Facebook], and some others) that you use on your mobile phone or tablet or computer or elsewhere.
In some countries it’s almost mandatory to use WhatsApp (which belongs to Facebook) if you want to communicate with others (no one texts in Argentina unless it’s on WhatsApp).
Therefore, the question is: what is data?
A Pragmatical Approach Of Data
First of all, for those wo learn better by doing go jump to lesson 2 on Google Colab by clicking on this link: https://colab.research.google.com/drive/11JMp2iv1Jl3MXzAgRNZKxhn0FkoA81Xm?usp=sharing
If you haven’t read lesson 1 go back do it RIGHT NOW! Here is the link:
Data Type
Nowaday, whether you like it or not, most of our communications with relatives and professionals are using digital devices (smartphone, computers, tablets, whatever).
All these devices could be really simplified with the computer model because at their core they are actually all computers.
Hence, understanding, at least the very basics, of the computer mecanism is very helpful and useful.
Some people say, as a joke, than computers are the meeting (or the match) between abstract logic and soldering iron (True and False with transistors).
In a way, it’s exactly that.
Anything that you can type on a keyboard, record with your microphone, record with your camera, draw with a mouse or a pen is finally encoded with two single symbols 0 and 1.
What Does That Mean? How The Hell Audio, Text, Videos Could Be Only 0 And 1?
That’s where data types come into the place!
Let’s start with something simple.
Let say you have an empty square (or call it a box if you prefer) that could store only 1 thing at a time, that specific thing we’ll call it INFORMATION unit.
Well, since a switcher could be only in two states open or close (you can only turn the light on or off) therefore it obeys to BINARY logic.
The switcher is important because it controls the arrival of electricity.
But let’s come back to our empty square (or box if you prefer).
In order to MODELIZE the information we use to single digits 0 to show void (no electricity, switch off, False) and 1 to show plenty (electricity, switch on, True).
So with 1 square (or box) we could describe 2 scenarii 0 or 1.
Therefore with 2 squares (or boxes) we could describe 4 scenarii: 00, 01, 10, 11.
Since we are using only 2 digits as the alphabet of symbols we call these symbols bits for BInary digITS.
Hence,
1 square means 1 bit of information and 2 scenarii possible.
2 squares means 2 bits of information and 4 scenarii possible.
3 squares means 3 bits of information and 8 scenarii possible.
4 squares means 4 bits of information and 16 scenarii possible.
5 squares means 5 bits of information and 32 scenarii possible.
For those who haven’t noticed yet, n bits of information can describe up to 2 to the power n of different scenarii.
The number of scenarii could be the number of characteristics to describe one specific physical object.
But let’s start with something simple, letters.
All the alphabetical characters on your keyboard are linked, each one with a specific number, for example the capital A is linked to the number 65 in the ASCII (American Standard Code for Information Interchange).
So, concretly, each time you use the capital letter A your computer is NOT understanding neither treating it as an alphabetical letter but as a code.
Actually, even the number code 65 is not treated as itself but converted in binary because computers only treat and understand BINARY (0s and 1s).
What I’m trying to tell you is, even chatGPT, perplexity or any other LLM DO NOT UNDERSTAND any data at all, they are just calculators who compute 0s and 1s nothing more!
The thing is that their computing power is so ridiculously fast that our brains cannot see the difference in many, many, many more and more cases.
But even though computers can count extremely fast they style need to organize their computations.
That’s precisely why we have DATA TYPES!
Data types serves to separate boolean data (binary data like True or False), integers (whole numbers like 0, 1, 2, 3, -5….), floats (decimal numbers like 0.1, -2.5, 3.14…) and many other that you will discover in the code: python4linguisticslesson2
Conclusion
If you have any question let me know in the comment section.
Everything on digital devices is data.
Every device is an actual computer.
Every computer is converting any data in binary code (0s and 1s).
But, in order to be more organized and efficient it uses data types.
A data type is a convention to group data that requires the same amount of space memory because at the end of the day you need to store data somewhere on your computer.
Data type is fundamentally a question of memory management.
If you learn something then share it to anyone you know because everyone is giving data without knowing how it works.