1.03 Skill-builder: Datatypes and Tables

Different kinds of data for every purpose...

Almost every programming language stores information differently according to what kind of information it is. The different kinds of information are called datatypes.

By learning HTML/CSS/Javascript, you will need to know the difference between boolean, hexidecimal, integer, floating point, character, string, and date datatypes. You will also have to learn about binary datatypes, because that is essentially how everything is broken down by computers at a fundamental level.

You are also going to learn how to create tables in HTML. Tables are constructed as a series of nested containers. Think of tables like this:

	<table>
		<caption>All I know about pickles</caption>
		<tr>
			<th>Pickle names</th>
			<th>Average pickle rating</th>
		</tr>
		<tr>
			<td>
				Polski ogorki<br />
				Bread and butter<br />
				Banana peppers
			</td>
			<td>9/10</td>
		</tr>
	</table>
						

Makes this...

All I know about pickles
Pickle names Average pickle rating
Polski ogorki
Bread and butter
Banana peppers
9/10

You will notice that in the Polski Ogorki... cell the information is divided by a <br /> tag. Use this if you want to start a new line without having a big gap between the lines.

Saving your work

Open your editor and save the empty document as "1.03S-DataTypes-LastName.html" in your Computer Programming 12 directory.

The assignment

  1. Create a table
  2. Organize the data into the table by correct datatype
  3. Create an ordered list of datatypes
  4. Add your own definitions to each datatype
  5. Extend: create a unordered list of your own quotes

Create a table that looks like this:

A table organized by type of data

Boolean ...
Binary ...
Hexidecimal ...
Integer ...
Floating point ...
Character ...
String ...
Date ...

Then organize the following data into the correct categories in the table you made. Separate the entries in the same cell with the <br /> tag.

You may also wish to use a paper version of this cut up into little cards.

A table of random types of data

October 13, 2014 11:13:00 85 1.618 #ff0000 "Don't undertake a project unless it is manifestly important and nearly impossible" -Edwin Land April 12, 1961 12:00:00
00100100 July 29, 1997 15:45:23 #000000 1 67 i
11001001 "A late game is only late until it ships. A bad game is bad until the end of time" -Shigeru Miyamoto "Hardware eventually fails. Software eventually works" -Michael Hartung September 22, 1997 04:05:06 1.414 11111111
January 30, 1997 20:14:35 January 1, 1970 00:00:00 00000000 ) c true
#0000ff e 65 #0a0a0a 7 "Perfect is the enemy of good" -Voltaire
3.1416 2.718 "All labor that uplifts humanity has dignity and importance and should be undertaken with painstaking excellence" -Martin Luther King, Jr. "I'm an engineer. I see myself as a toolmaker and the musicians are my customers... They use my tools" -Robert Moog false 01000010
#ffffff ;

Then create an ordered list that looks like this: (Use <ol><li></li></ol>.)

My datatype definitions

  1. Boolean = A boolean is either ...
  2. Binary =
  3. Hexidecimal =
  4. Integer =
  5. Floating point =
  6. Character =
  7. String =
  8. Date =

Write definitions for each term using your own words after each term.

Extend and expand

I am curious which people you find inspirational. Please create an unordered list <ul><li></li></ul> of quotes from people whom you admire.

Quotes from awesome people: