Data2:28 with Joy Kesten
At the most basic level, when a computer runs an application, it follows the list of instructions you or another person has written. This list of instructions is called a program. Often programs take in or spit out data. Whether you're checking the weather or writing a paper, programs are constantly handling data.
[MUSIC] 0:00 At the most basic level, when a computer runs an application, 0:04 it follows the list of instructions you or another person has written. 0:08 This list of instructions is called a program. 0:13 Often programs take in or spit out some form of data. 0:16 Whether you're checking the weather or writing a paper, 0:20 programs are constantly handling data. 0:22 Data [SOUND] itself is a piece or pieces of information. 0:25 Almost all data is ultimately represented in [SOUND] binary form. 0:29 Meaning [SOUND] data at its essence is just a series of 0s and 1s. 0:33 [SOUND] These binary digits, 0 and 1, 0:38 can be represented easily using electrical circuits. 0:41 A bit, which is like a switch, is either off or on. 0:45 If the switch is off, it's a 0. 0:49 If it's on, it's a 1. 0:51 An easy way to visualize binary is on a circuit board. 0:54 To represent 1 and 0, we use high and low voltages to turn an LED on and off. 0:58 Let's use this Texas Instrument launch pad for a tangible example of binary. 1:06 We're using HIGH to turn the LED on to represent the binary 1. 1:11 And to turn the LED off, we'll use LOW or the binary 0. 1:17 But say instead I wanted to loop it from on to off or 1 to 0 and back again. 1:23 I might write a program that looks like this. 1:30 Turn it on, wait for a second, turn it off, wait for a second. 1:35 Turn it on, wait for a second, turn it off, wait for a second. 1:41 Now, this code is using Energia, which we don't really teach here at Treehouse. 1:46 But if you're interested, in the teacher's notes I've linked the wiki page 1:51 that you can find on GitHub and the link to the microcontroller I'm using. 1:56 The fundamental building blocks of a computer is this idea of a switch, 2:01 on or off. 2:05 In a digital computer, this switch takes the form of a transistor. 2:07 Before digital computers, they used vacuum tubes to do this. 2:11 In order to store data or run programs, we need to first convert the programs 2:15 into something that can actually be performed by the physical hardware. 2:19 In most cases, this means turning the programs we write into binary. 2:23
You need to sign up for Treehouse in order to download course files.Sign up