660 likes | 745 Views
Languages of Computing. Alan Blackwell CU Computer Laboratory. Part 1. Languages for storing data. Binary digits (bits). = 1. = 0. Bits. = 0100100. Bytes. 01000001 01101100 01100001 01101110 00100000 01000010. Encoding text. 01000001 = “A” 01101100 = “l” 01100001 = “a”
E N D
Languages of Computing Alan Blackwell CU Computer Laboratory
Part 1 Languages for storing data
Binary digits (bits) = 1 = 0
Bits = 0100100
Bytes 01000001 01101100 01100001 01101110 00100000 01000010
Encoding text 01000001 = “A” 01101100 = “l” 01100001 = “a” 01101110 = “n” 00100000 = “ ” 01000010 = “B” etc …
Floppy disk drive 1.4 megabytes = 1.4 million bytes = 1,400,000 bytes = 1,400 kilobytes
Hard disk drive (gigabytes) 400 gigabytes = 400 billion bytes = 400,000,000,000 bytes = 400,000,000 kilobytes = 400,000 megabytes
External hard drive (terabytes) 1 terabyte = 1 trillion bytes = 1,000,000,000,000 bytes = 1,000,000,000 kilobytes = 1,000,000 megabytes = 1,000 gigabytes
Geek speak checklist • bit, byte, RAM • kilobyte (kB) = 1,000 bytes • megabyte (MB) = 1,000,000 bytes • gigabyte (GB) = 1,000,000,000 bytes • terabyte (TB) = 1,000,000,000,000 bytes • ASCII
Part 2 Types of data language
Numbers 0 = 00000000 1 = 00000001 2 = 00000010 3 = 00000010 … 254 = 11111110 255 = 11111111
Encoding colour 11001000(= 200 Red) 01100100(= 100 Green) 11001000(= 200 Blue) 110010000110010011001000
Picture elements (pixels) 900 pixels(30 x 30)
Compression 36,000 pixels (180 x 200) JPEG level 12 (high quality) File size: 40 kB 36,000 pixels (180 x 200) JPEG level 0 (low quality) File size: 14 kB
Resolution A 10 kPixel camera (100 x 100 greyscale)
Encoding sound .WAV[e] file or (compressed) MP3 0 | 0 | 237 | 10 | 56 | 235 | 12 | 3 | 45 | …
Encoding programs 10100000 00000000 01000010 11101001 01001000 = MOV AX,0x0082E984H or, “get the data at memory address 4385096” (in the particular language of Intel microprocessors)
Central Processor Unit Once millionsof instructions per second (MIPS) Now, billions of clock ticks per second (GigaHertz, GHz)
Geek speak checklist • plain text • resolution • compression • GIF, JPEG, MP3, WAV, MPEG • ARM • GigaHertz
Part 3 Collecting and presenting data
Input: Flatbed scanner 1000 dpi (dots per inch)
Input: Digital camera 4000 x 3000 = 12 Megapixels
Input: Digital video camera 640 x 480 pixels (VGA)
Input: Webcam 352 x 288 pixels (VGA)