Computer Science, Crash Course (YouTube) Flashcards
What’s first example of calculating machine?
Abacus
(Mesopotamia 2500 BCE)
Who said: “At each increase of knowledge, as well as the contrivance of every new tool, human labour becomes abridged”?
Charles Babbage
(1791-1871)
Who invented the Step Reckoner?
1694
Gotfried Leibnitz
Could do add/subtract/multiply/divide - first machine that could do this
How were artilery calculations performed traditionally?
Using range tables - taking into account distance, wind speed, weather etc
Used well into WW2
Who invented the Difference Engine, capable of solving polynomials?
Charles Babbage
What did Babbage come up with after the Difference Engine?
Analytical Engine - first multi-purpose computer, can run steps in sequence, store results, even with a printer
Who was the first person to write hypothetical programs for the Analytical Engine? The first “programmer”?
Ada Lovelace
(1815-1852)
How was the US census of 1890 helped by the use of computers?
Manually it would have taken 13 years
Herman Hollerith developed electro-mechanical system using tabulations and punch cards e.g. a hole punched for marital location, this would enable a circuit at that location which would turn a motor and added one (to the married total)
Sped up things by 10 times
Hollerith’s machine tabulating company merged with others to become what in 1924?
IBM
What was the Harvard Mark I and what was the main component that it used?
1944 at Harvard, used by Allies (e.g. running simulations for Manhattan Project)
Could do three additions or subtractions per second
Based on the “mechanical relay” switch
What design improved the mechanical relay?
Vacuum tube - no moving parts, this is a move to “electronic computing”
What was the first electronic computer (using vacuum tubes)?
Colossus Mark I
1943
Bletchley Park - code breaking Nazi messages
First programmable computer
What was the true first general purpose programmable computer?
ENIAC
1946
Uni of Penn
Operational for 10 years
More arithmetic that the entire human race up to that point
~17.5K vacuum tubes
What followed the vaccum tube and who invented it?
Transistor
Bell Labs in 1946
What was the first commercial transistor computer?
IBM 608
1957
Contained 3000 tranistors
Could do 4,500 additions per second
How big are transistors today?
Smaller than 50 nanometers
(paper is 100,000 nanometers)
What are the 3 basic logic gates that can be built with transistors and what are their symbols?
NOT (triangle with dot)
AND (D shape)
OR (spaceship shape)
How can you use the basic gates to build an XOR?
(OR gate)
AND
(NOT(AND))
What system replaced ASCII?
Unicode in 1992
(based on 16 bits)
Which part of the processor does computations like calculating?
Arithmetic and Logic Unit (ALU)
What is the first chip that has an ALU completely in it?
Intel 74181
(1970)
Logic gates can be thought of as “…” for the individual transistors
abstractions
Give an example of overflow affecting real life applications?
Pacman used 8-bits to store scores, once you got past level 255, the ALU overflowed resulting in glitches to the game
Became a right of passage for Pacman players
Why do simple ALUs not have multiplication and division circuits?
Because you can simplify them to addition and subtraction operations
How many bits and logic gates did the famous Intel 74181 chip have
4 bits
70 logic gates
What are the symbols used for ALU operations?
E.g. for an 8 bit ALU
V symbol
* Input A and Input B go in at the top (each 8 bits)
* Operation code (4 bits) from the left
* Flags from the right (overflow, zero, negative)
* Output (8 bits)
Which logic gates can be used to store states i.e. memory?
And-Or Latch
What is the name given to a group of latches, holding a single number? And the number of bits is knows as it’s […]?
Register
Width
Today many chips are 64 bit wide
How much RAM does my M2 chip have?
8 GB
(= 8 * 8 * 1024 * 1024 * 1024 = ~64B bits)
Which component chooses the right address to read/write memory to?
Multiplexer
The first single chip CPU Intel 4004, had what clock speed? (1971)
740 kHz
What’s the clock speed of my M2 mac?
3.49 GHz
(3.5 billion cycles per second)
What are the main components in a CPU?
Clock
Control Unit
Registers
ALU
How many instructions did the first fully integrated chip (Intel 4004) have?
46 instructions
Modern chip has thousands
What is the name of the entity that connects CPU chip to RAM?
Bus
What’s cache?
Piece of memory that sits on the chip to speed operations up
A block of data is moved from RAM to cache
Closer to CPU so cache can be accessed more quickly (in one clock cycle, say, rather than waiting for a few clock cycles)
What cache does the M2 apple chip have?
192 KB of L1 instruction cache
and 128 KB of L1 data cache
and share a 16 MB L2 cache
If the data is found in cache, what’s it called?
Cache Hit
If data in cache is different from RAM, how is this flagged in the cache?
via a “dirty bit”
What are the building blocks of the CPU cycle?
Fetch
Decode
Execute
What chip powers my Mac, and how many transistors?
M2
20b transistors
What chip powers my iPhone and how many transistors?
A15 Bionic chip
15b transistors
What are the five areas of the chip making industry?
- ISA = Instruction Set Architecture
- Chip design
- Fabrication
- Software and equipment
- Packaging and testing
What are the two main ISA’s and which chips and OS’s use them?
x86 > Intel and AMD > Windows, Mac, Linux
Arm > multiple makers > Android
What are the CapEx ratios (of revenue) for chip designers vs. chip fabs?
Designers: 3-5%
Fabs: 30-50%
Who is the biggest chip maker (foundry)? and market share?
TSMC
Over 50%
EUV Lithography machines - who makes them?
ASML (Dutch company)
How many machines does ASML make per year?
25
(each one costs $120m)
What’s a multi-core processor?
Can run instructions in parallel, whilst sharing some commone components like cache
What’s a FLOP?
Floating Point Operation per Second
What did Joseph Marie Jacquard develop?
Programmable textile loom
1801
Using punched cards to create patterns
How would you program the early bsuiness machines?
Using control panel, move plugs/wires around, could take weeks
What is the design called when you store instructions and data in memory?
Von Neuman Architecture
What was the first Von Neumann Architecture machine?
Baby
Univeristy of Manchester
1948
How would instructions and data be programmed into memory?
Using Punch Cards
(well into the 80’s)
What was the first home computer and how was it used?
Which year?
Altair 8800
1975
Using switches to load it with instructions and data
What is machine code?
instructions and data given to computer in binary (0’s and 1’s) that the circuits can directly deal with
Think Altair 8800
What is assembly code?
Layer of abstraction, now you can write text to represent intstuctions and data e.g. “Load_A 15”
One to one mapping to assembly code
What was the next level of abstraction after assembly code?
Compiler
One line could translate into many lines of machine code
Generally 20x shorter than assembly code
With a small computational inefficiency added
Who came up with the concept of a compiler?
Dr Grace Hopper
1952
A0 language
What was the first programming language that gained traction and who invented it?
Fortran
1957
Dr John Backus for IBM
What came after Fortran?
COBOL
1959
That could be written once and then run on any machine (once compiled)
Where does “algorithm” come from?
Al Khwarizmi
780-850
One of the founders of algebra
What episode started off the use of microelectronics in bomb warfare?
1972 bombing of Thanh Hoa Bridge in Vietnam
Previously tried 638 times without success
Using Texas Instruments chips inside it was now able to precisely hit the target (Paveway laser-guided bomb)
Who was Taiwan’s first dictator?
Chian Kai-shek
What happened in the 70’s with the global manufacture of semiconductors?
American firms set up chip plants in Taiwan, Singapore, Malaysia, etc.
Creating a strong US and South East Asia alliance
Shielded these countries agains the domino effect of communism after US pulled out of Vietnam in 1975
When was Intel founded and by whom?
1968
Bob Noyce and Gordon Moore
(They left Fairchild b/c of lack of stock options and meddling from NYC HQ)
What was Intel’s first product?
DRAM
Dynamic random access memory chip
(1970)
What was Intel’s first big breakthrough product?
Processor chip 4004
A programmable computer
What’s a Turing Machine?
- Theoretical model of a computer
- Infinitely long memory tape
- State variable and rules (based on state and what it’s ruling)
- It can change state, move read/write head left or right
- This gives us a general purpose computer
What does CAPTCHA stand for?
Completely Automated Public Turing test to tell Computers and Humans Apart
How many lines of code does MS Office have?
around 40 million
What is object oriented programming?
An object can contain other objects, functions, and variables
Think of a car program
Object is car
Which contains other objects like engine, wheels, doors
The engine object conatins nested objects, functions and variables
Programmer can navigate down the hierarchy such as “Car.Engine.CruiseControl.setCruiseSpeed(55)” - this calls the relevant function
the aim is to package simple/small things into increasing levels of complexity - “abstraction”
What’s the difference between Public and Private functions?
Public funcitons can be called from without the Object, e.g the CruiseControl team can call SetRPM which is contained within the ignition Object
Private functions can only be called from within the Object. E.g. SetRPM within the Ignition Object can only be called within that Object. The CruiseControl team cannot access it
How much time do developers spend on debugging/testing?
70-80%
What was the first task of the operating system?
Helping to
load programgs (which were done by hand)
It could “batch process”
What was the first computer to allow for multi-tasking?
Atlas
Manchester University
1962
It did this through scheduling
What was Unix?
An early operating system
In the 1970’s
Separated a lean “kernel” (for multi-tasking, virtual memory, dealing with I/O,…) and an additional part for useful tools
Instead of lots of error checking, there was a kernel panic routine that crashes the machine
One of the most popular OS’s throughout ’70s and ’80s
What was Microsoft’s first OS?
MS DOS (Disc Operating System)
1981
What was the original computer storage?
Punch cards
What was the largest program ever punched onto cards?
SAGE 1958 military defense system
62,500 punch cards (5Mb of data - a smartphone photo)
What was an early form of memory?
EDVAC
delay line memory - sending pulses through mercury
1949
Stored program computers
What took over in mid 1950’s for memory?
magnetic core memory
donut rings that can be read/written
What popular memory technique was there in the 50s and 60s?
magnetic tape
How much storage does my MacBook Air have?
245 GB
what’s a solid state drive (SSD)? What’s benefit over HDD?
An SSD, or Solid State Drive, is a type of data storage device that uses integrated circuit assemblies to store data persistently, typically using flash memory.
It serves the same function as a hard disk drive (HDD), but SSDs are faster because they have no moving parts, which allows for quicker access times and data transfer rates.
What’s size of photo on iPhone?
1-3Mb
What are the two types of compression?
Lossless e.g. text, pics
Lossy e.g. audio, pics, video
Who invented the typewriter?
Christopher Latham Sholes
the “literary piano”
1868
(where QWERTY comes from)
What was the development of interfaces in the 60s and 70s?
Computer I/O controlled by Command Line Interface
First TeleType and later screens
What are two types of screen technology?
CRT = cathode ray tube
LCD = liquid crystal display
How would early screens function?
Grid of characters (in order to be memory efficient and not have to store the value of each pixel)
Or vector graphics
What came after character grids and vector graphics?
Bitmap display - each pixel (or block of pixels) controlled by bits
What was the first successfully commercial computer?
UNIVAC 1
More than 40 built (for government and large companies)
Early 1950s
E.g used for 1952 election to predict Eisenhower landslide
Who was the first man in space?
Yuri Gagarin
1961
What was Bill Gates and Paul Allens idea that they suggested to the maker of the Altair 8800?
They would develop an interpreter that allowed conversion of BASIC instructions to machine code.
Who put together a personal computer using keyboard and screen in 1976?
Steve Wozniak
Led to Apple 1
Sold as a kit for hobbyists
1976
What was the 1977 Trinity that sparked the rise of home computing? What did they come installed with?
- Commodore Pet 2001
- Apple II
- TRS-80 Model I
Installed with BASIC interpreters
What was the first breakout app for personal computing?
1979
VisiCalc (originally released for Apple II)
Who were the dirty dozen of IBM?
Twelve engineers who moved away from in-house development
Used partners for software and hardware
Intel chips, MS-DOS, open architecture, spurring innovation and ecosystem (IBM compatible) … in the 80s
What were competing strategies for the personal computer market?
IBM - open architecture (“IBM compatible”)
Apple - closed
What was first computer to offer a graphical user interface (as opposed to command line)?
Macintosh 1984
Who designed sketch pad?
Ivan Sutherland (1962)
Who invented the mouse?
1964
Englabert and English
What was called the “mother of all demos”?
Douglas Engelbart
1968 demo of mouse, collaboartive working, multiple windows, bitmap graphics, word processing
Elements of modern computing
But ahead of its time
Who invented the idea of a desktop with multiple windows and useful apps?
Xerox PARC
Bill English and team
Finished in 1973
WIMP interface - Windows Icons Menus Pointer
What was wrong with Xerox Star?
early 1980’s
impressive GUI
but price tag equivalent of $200k for an office set up
sluggish sales
couldn’t compete with cheap IBMs
Who was a beneficiary of Xerox’s pushing the envelope?
Steve Jobs at Apple
Inspired by Xerox’s intuitive approach and metaphors
What came out in 1985 in the OS market?
Windows 1.0
(not as pretty as Mac OS but paved the way for domination - 95% market share within 10 years on PC’s)
What was the point at which Microsoft radically improved its GUI?
Windows 95
What is 3D projection?
Taking 3D coordinates (x,y,z) and projecting them onto a 2D plane (x,y) using WIREFRAME RENDERING
imagine taking a 3D model of a cube made from chopsticks and shining a light on it and seeing the projection onto a wall
What are the two types of 3D projection
Orthogographic (parallel sides in cube appear parallel in projection)
Perspective projection (non parallel sides of cube as they converge)
How are 3D objects rendered - using which shape?
triangles - simplest number of points to define a plane in space
What’s anti-aliasing (in graphics)?
Pixels within polygon get stronger colour than those at the edges which are only partially in (look at text in a browser, close up)
What are the main techniques for graphics rendering?
Name four
Scanline filling
Lighting
Anti-aliasing
Texture mapping
Why are GPUs used?
They can do lots of calculations in parallel
What was the sneakernet?
Physically taking a set of punch cards or magnetic tape from one side of the building to the other (rather than sending if over a network)
The first networks arose in the 60s and 70s. they were…
LAN - local area networks e.g. for sharing a printer or storage
The most widely used LAN is called what? explain how it works
Ethernet
Message sent across cable to all computers, it’s only read by the computer with the correct address (Media Access Control or Mac address)
How do ethernets avoid collisions?
Try sending message again after waiting for a random brief pause
Uses exponential “backing off” time period
What technique does the ehternet use to avoid collisions?
Divides up bigger network into smaller ones and then there’s a switch between them for instances when one side of the network needs to pass to another
What is Circuit Switching in the context of networks?
creating a dedicated line between A and B e.g. early phone systems used this
But it’s inefficient
What is message switching (in routing)?
You send message via various nodes - not necesarily a determined route like with postal service
What approach does the internet take to routing data?
Packet switching
Chops up data into packets
These are all sent along different routes and reassembled on the other side
What was the first internet?
ARPANET
Packet switching
Advanced Research Projects Agency
Early 1970s
In your house what is your LAN?
all devices connected to your wifi router
What’s the route of data flow across the internet?
From LAN
To WAN (from your ISP) for your city then maybe a bigger one
Then connecting to the backbone
Then coming off this to connec to the YouTube server
E.g. 10 hops - 4 hops up to the backbone, 2 hops along, 4 hops down
What’s the difference between the internet protocols: UDP/IP and TCP/IP
UDP sends the packet with minimal additional information, such as port number and check-sum
TCP adds in much more - including sending back Acknowledgements, Number for sequencing,
What’s the DNS?
Domain Name System
List that matches website names to IP addresses
What are the layers of the internet?
Conceptual framework…
* Physical layer (wires or wifi)
* Data link layer (MAC addresses, collisions, back-off)
* Network layer (switching and routing)
* Transport layer (UDP and TCP protocols)
* Session layer (open a connection, close a session)
Who created the first web browser and server?
Sir Tim Berners Lee in 1990
(whilst at CERN)
In 1993 a web browser was developed in University of Ilinois allowing for dispaly of images as well as text. It was called…
Mosaic
What was the precursor to Yahoo?
Jerry and Dave’s guide to the worldwide web (renamed to Yahoo in 94)
What was the first web search engine?
Jump Station
1993
Jonathan Fletcher
What was Google’s innovation?
To rank not based on number of mentions of the word, but on hyperlinks into there (gives it more authority based on backlinks))
What is net neutrality?
idea that packets should all be treated with equal priority
What are 3 aims of computer security?
- Secrecy - avoid people seeing what they should not see
- Integrity - only permitted people can access and modify system and data
- Availability - programs and data are available when needed
What are 3 types of authentication?
What you know
What you have
Who you are
What are two pillars of keeping computers secure?
Authenticaion
Access Controls
What’s the current standard of encryption?
Advanced Encryption Standard
…
trusted standard algorithm used by the United States government, as well as other organizations. Although extremely efficient in the 128-bit form, AES also uses 192- and 256-bit keys for very demanding encryption purposes
What’s the name of the table that summarizes the success/failure rate of machine learning predictions?
Confusion matrix
A branch of AI that doesn’t rely on classical statistics is …
Neural networks
What are the 3 types of layers in the neural network?
Input
Hidden
Output
What are two examples of deep learning successes (pre-OpenAI)?
Watson in 2011 winning Jeapordy
2016 Alpha Go success
What is a kernel (coputer vision)?
Small matrix that is used to apply effects to images (blurring, sharpening etc.)
It works by sliding over each pixel and calculating a new value (based on values of neighbouring pixels, and pixel itself)
A kernel applied across an image is also known as a (…)
convolution
Using a series of layers in a neural network to define different types of kernels and process an image is called…
Convolutional Neural Network
Using rules we can decode a sentence of words into a structured…
Parse Tree (identifying the differenet pars of speech: nouns, verbs, adverbs etc.)
What chatbot was created in mid-60’s in MIT?
Eliza
(took on role of therapist)
What was first speech recognition program?
Audrey
1952
Bell Labs
(could recognize all ten digits, spoken)
Where does the term robot come from?
1920 play - artificial humanoid characters (from “robota”, peasants in compulsory service)
What’s an android?
robot that looks and acts like a human
Making items intutitive for the user so that they automatically know what to do with them is called…
Affordance
a term that describes the “eerie sensation” one feels when they encounter a robot with human-like characteristics.
Uncanny valley
What did Thomas Edison predict about books, in 1913?
That they will soon be obsolete in schools; every branch will be taught using the motion picture.
What is the singularity?
Term by John Von Neumann
A point beyond which human affairs as we know them could not continue
(1950s)
What are two axes in which you can divide jobs into?
Manual-Cognitive
Routine-Non Routine
Top right quadrant could be lawyer, doctor, teacher,… (40% of workforce)