Beginner's Guide to Coding and Data

Level: Beginner

Text to Binary explained | Introducing bits and bytes for programming beginners

video

expand_more chevron_left

text

expand_more chevron_left

Text to Binary Transformation

So, how do we transform the text, like deeplizard, into its binary form? We'll walk through the ins and outs.

In order to nail this concept down, we need to use the following foundational topics:

  • Character Encoding
  • Positional Numeral Systems

If you stumble upon any difficulties, don't hesitate to review the lessons on character encoding and positional numeral systems. They'll pump up your knowledge on the subject.

The Transformation Process

We'll take the example of the text deepLizard and show how it converts to binary. The transformation involves two crucial steps:

  1. Convert each character to its Unicode character code
  2. Transform each base-10 code to its base-2 binary form

Under the Hood of Computers

In essence, computers only deal with numbers. By under the hood, we mean the hardware part of the computer. When we talk about numbers, we're referring to numerals based on the binary positional numeral system.

Therefore, it's crucial for us as programmers to understand that all data, be it text or numerical, is ultimately translated to binary for hardware processing.

Bits and Bytes

Each binary numeral consists of 8 digits, which we call bits. A bit can either be 0 or 1, representing the states off and on respectively.

A sequence of 8 bits is known as a byte. For example, the text deepLizard is represented as 10 bytesβ€”one byte for each character.

A Practical Exercise

Give it a try. Open a text editor, type in deepLizard, and save the file. Check its properties, and you'll find it takes up 10 bytes of space.

It's fascinating to see how text representation can sometimes require more than one byte per character, depending on the encoding scheme.

quiz

expand_more chevron_left
deeplizard logo DEEPLIZARD Message notifications

Quiz Results

resources

expand_more chevron_left
The key to understanding how we transform text into binary is to first understand character encoding and then to understand positional numeral systems. Prerequisites videos: Numerical data explained - https://youtu.be/YDDqe60omL0 Textual data explained - https://youtu.be/-XLZadCdo9Q Unicode explained - https://youtu.be/M8CbBfx5228 Numeral vs Number - https://youtu.be/RSdnNZBj8HQ Binary vs Decimal - https://youtu.be/-MM6PcEQnWc Hexadecimal explained - https://youtu.be/JlLnt4aJEK0 5 Patterns with Numbers - https://youtu.be/-iMpJ-xGG4k Related video: Is your name also a number? - https://youtu.be/jxYi4RGlIV4 Notebook - https://beta.observablehq.com/@deeplizard/text-to-binary-and-back πŸ•’πŸ¦Ž VIDEO SECTIONS πŸ¦ŽπŸ•’ 00:00 Welcome to DEEPLIZARD - Go to deeplizard.com for learning resources 00:30 Help deeplizard add video timestamps - See example in the description 06:19 Collective Intelligence and the DEEPLIZARD HIVEMIND πŸ’₯🦎 DEEPLIZARD COMMUNITY RESOURCES 🦎πŸ’₯ πŸ‘‹ Hey, we're Chris and Mandy, the creators of deeplizard! πŸ‘€ CHECK OUT OUR VLOG: πŸ”— https://youtube.com/deeplizardvlog πŸ’ͺ CHECK OUT OUR FITNESS CHANNEL: πŸ”— https://www.youtube.com/channel/UCdCxHNCexDrAx78VfAuyKiA 🧠 Use code DEEPLIZARD at checkout to receive 15% off your first Neurohacker order: πŸ”— https://neurohacker.com/shop?rfsn=6488344.d171c6 ❀️🦎 Special thanks to the following polymaths of the deeplizard hivemind: Mano Prime πŸ‘€ Follow deeplizard: Our vlog: https://youtube.com/deeplizardvlog Fitness: https://www.youtube.com/channel/UCdCxHNCexDrAx78VfAuyKiA Facebook: https://facebook.com/deeplizard Instagram: https://instagram.com/deeplizard Twitter: https://twitter.com/deeplizard Patreon: https://patreon.com/deeplizard YouTube: https://youtube.com/deeplizard πŸŽ“ Deep Learning with deeplizard: AI Art for Beginners - https://deeplizard.com/course/sdcpailzrd Deep Learning Dictionary - https://deeplizard.com/course/ddcpailzrd Deep Learning Fundamentals - https://deeplizard.com/course/dlcpailzrd Learn TensorFlow - https://deeplizard.com/course/tfcpailzrd Learn PyTorch - https://deeplizard.com/course/ptcpailzrd Natural Language Processing - https://deeplizard.com/course/txtcpailzrd Reinforcement Learning - https://deeplizard.com/course/rlcpailzrd Generative Adversarial Networks - https://deeplizard.com/course/gacpailzrd Stable Diffusion Masterclass - https://deeplizard.com/course/dicpailzrd πŸŽ“ Other Courses: DL Fundamentals Classic - https://deeplizard.com/learn/video/gZmobeGL0Yg Deep Learning Deployment - https://deeplizard.com/learn/video/SI1hVGvbbZ4 Data Science - https://deeplizard.com/learn/video/d11chG7Z-xk Trading - https://deeplizard.com/learn/video/ZpfCK_uHL9Y πŸ›’ Check out products deeplizard recommends on Amazon: πŸ”— https://amazon.com/shop/deeplizard πŸ“• Get a FREE 30-day Audible trial and 2 FREE audio books using deeplizard's link: πŸ”— https://amzn.to/2yoqWRn 🎡 deeplizard uses music by Kevin MacLeod πŸ”— https://youtube.com/channel/UCSZXFhRIx6b0dFX3xS8L1yQ ❀️ Please use the knowledge gained from deeplizard content for good, not evil.

updates

expand_more chevron_left
deeplizard logo DEEPLIZARD Message notifications

Update history for this page

Did you know you that deeplizard content is regularly updated and maintained?

  • Updated
  • Maintained

Spot something that needs to be updated? Don't hesitate to let us know. We'll fix it!


All relevant updates for the content on this page are listed below.