Computer science study guide

Computer Foundations and Core Concepts

The fundamental relationship driving computer science learning is described by the Exposure Equation:

Bewilderment+Exposure=Obvious\text{Bewilderment} + \text{Exposure} = \text{Obvious}

In classroom environments, the student-teacher relationship is the most critical element of learning. Computer Science is strictly distinct from Computer Literacy or Computer Applications; Computer Science is essentially computer programming. The primary focus of computer architecture study is understanding how a computer operates.

Computers Versus Humans

Computers excel over human capabilities in three specific areas:

  1. Faster execution speed

  2. Higher accuracy

  3. Inability to forget

When computers produce incorrect output, the cause is typically attributable to faulty human instructions or sloppy data entry. Computers possess no independent intelligence or creativity; they exclusively follow programmed instructions.

Artificial Intelligence Stages

Artificial Intelligence (AI) currently exists at the stage of Artificial Narrow Intelligence (ANI). Narrow AI systems are specifically designed to execute single, dedicated tasks. Examples of ANI include:

  • Siri

  • ChatGPT

  • Self-driving cars

Data Representation, Binary, and Encoding

Morse Code and Binary Systems

Morse Code demonstrates how electrical signals transmit information through patterns of short and long signals (ON and OFF states). Examples of letter representations in Morse Code include:

  • J: .---

  • U: ..-

  • L: .-..

  • I: ..

  • A: .-

  • N: -.

Computers store all digital information using binary representation:

  • 1=ON1 = \text{ON}

  • 0=OFF0 = \text{OFF}

Number systems differ by their mathematical bases:

  • Decimal System: Base 10, utilizing digits 0 through 9.

  • Binary System: Base 2, utilizing only digits 0 and 1.

Bits, Bytes, and Character Encoding

Information storage components and character encoding standards follow strict definitions:

  • Bit: Short for Binary Digit.

  • Byte: Formed by 8bits8\,\text{bits}.

  • ASCII: Originally a 7-bit encoding system where standard characters fit into 1byte1\,\text{byte}. The ASCII decimal code for capital Z is 90.

  • Unicode: Standard created to accommodate significantly more characters than ASCII.

  • UTF-8: The most popular Unicode encoding system, utilizing between 1byte1\,\text{byte} and 4bytes4\,\text{bytes} per character.

Character encoding systems are case-sensitive, meaning uppercase and lowercase characters have distinct binary and ASCII representations (Aa\text{A} \neq \text{a}).

Computer Hardware, Storage, and Architecture

Early Computing and Hardware Evolution

  • ENIAC: The first electronic general-purpose computer. It utilized over 17,000 vacuum tubes for electronic memory.

  • Vacuum Tubes: Early electronic memory devices capable of representing ON (11) and OFF (00) states. They were large, generated significant heat, and were prone to burning out.

  • Transistors: Replaced vacuum tubes because they were much smaller and did not generate heat or burn out.

  • Microchips: Evolved from transistors and integrated circuits. Modern microchips contain billions of transistors constructed on silicon.

  • Motherboard: The main printed circuit board holding primary hardware components.

Memory and Central Processing Unit

  • ROM (Read Only Memory): Stores permanent information that remains intact when power is turned off.

  • RAM (Random Access Memory): Stores temporary information that disappears when power is removed.

  • CPU (Central Processing Unit): Functions as the brain of the computer, executing processing tasks and mathematical calculations.

Data Storage Scale

Storage capacity increases systematically across standard metrics:

  1. KB (Kilobyte) 103bytes\approx 10^3\,\text{bytes} (one thousand bytes)

  2. MB (Megabyte) 106bytes\approx 10^6\,\text{bytes} (one million bytes)

  3. GB (Gigabyte) 109bytes\approx 10^9\,\text{bytes} (one billion bytes)

  4. TB (Terabyte) 1012bytes\approx 10^{12}\,\text{bytes} (one trillion bytes)

  5. PB (Petabyte)

  6. EB (Exabyte)

  7. ZB (Zettabyte)

  8. YB (Yottabyte)

A Terabyte (TB) holds substantially more data capacity than a Gigabyte (GB).

Analog versus Digital Signals

  • Analog: Measures physical phenomena in a continuous fashion (e.g., needle speedometers, measuring tapes, traditional mechanical clocks).

  • Digital: Stores precise numerical representations, allowing exact copies of original data to be duplicated without loss.

Software Types and Operating System Operations

Hardware and Software Classification

  • Hardware: Physical components that can be seen and touched, such as monitors, keyboards, mice, printers, and hard drives.

  • Application Software: Software designed to perform specific user-oriented tasks (e.g., word processors, spreadsheets, paint programs).

  • System Software: Software necessary for the computer hardware to operate properly, primarily the Operating System (OS) such as Windows, Mac OS, UNIX, and Linux.

Operating System Terms and File Operations

Windows Term

Mac Equivalent

Function

Taskbar

Dock

Displays frequently used applications

Shortcut

Alias

Points to a file or folder located in another directory

This PC

Finder

Provides access to file systems and storage drives

  • Removable Storage Handling: USB jump drives must be properly ejected before physical removal to prevent data corruption. In Windows, right-click the USB drive and select Eject. In Mac OS, drag the USB icon to the Trash/Eject destination.

  • Data Management Definitions:

    • Copy: Transferring files from local physical media to local storage.

    • Download: Receiving files from a remote server to a local client.

    • Upload: Sending files from a local device to a remote server.

    • Install: Writing required executable files and configuration settings to designated hard drive locations so software operates correctly.

    • FTP: File Transfer Protocol.

  • System Configurations and Environment Rules:

    • Default Settings: System configuration parameters preset by software manufacturers.

    • File Extensions: Hidden by default in standard Windows and Mac file managers.

    • OS Visual Indicators: The Windows 10 Recycle Bin icon faces diagonally left, whereas the Windows 11 Recycle Bin icon faces straight forward.

    • Drive Identifiers: Windows assigns the default primary hard drive letter as C: . Default user libraries include Documents, Pictures, Music, and Videos.

    • Specialized Hardware Limits: Tablets like iPads and Chromebooks are not full-fledged computer systems. Identical computer models may display different behaviors due to contrasting configuration settings.

Programming Concepts, Languages, and Environments

Programming Lifecycle and Language Hierarchy

  • Program: A sequential set of instructions that enables a computer to execute designated operations.

  • Coding: The specific physical act of typing program statements into a development environment (a sub-component of overall programming).

The 5 steps of the programming process must occur in order:

  1. Identify what needs to be done

  2. Develop a plan for how to do it

  3. Code the plan

  4. Test and debug

  5. Update when necessary

  • ENIAC Programming: Required manual rewiring of hardware connections.

  • Grace Hopper: Developed the first computer compiler in 1952 for the A-0 programming language.

Languages exist across three architectural levels:

  • Low-Level Languages: Direct machine representation using 1s and 0s.

  • High-Level Languages: Human-readable English words and structured syntax (e.g., Python, Java, FORTRAN, COBOL, C, C++).

  • Very-High-Level Languages: Visual programming utilizing pictures or graphical icons.

Program Translation Mechanisms

  • Compiler: Translates an entire source code program into machine-executable files prior to execution. Modern languages favor compilers due to execution speed and operational efficiency.

  • Interpreter: Translates and executes source code line-by-line during runtime.

Programming Language Characteristics

  • FORTRAN: Built specifically for scientists, mathematicians, and engineers.

  • COBOL: Designed explicitly for commercial business applications.

  • C: Merged high-level readability with low-level direct access.

  • C++: Expanded C by introducing Object-Oriented Programming (OOP).

  • HTML: HyperText Markup Language used by web browsers to structure web documents.

  • Python: Simple, powerful language utilizing an interpreter.

  • Java: Platform-independent object-oriented language.

Software Setup Specifications

  • Renaming Python Executable: On Windows systems, the Python binary py.exe must be renamed to python.exe so integrated development environments like jGRASP can locate the runtime executable.

  • Java Dependencies: Development environments such as jGRASP require the Java Runtime Environment because jGRASP itself is written in Java.

  • Language Support: jGRASP is not exclusive to Python; it supports multiple languages including Java.

Networking and Internet Principles

  • Sneaker Net: Physical transfer of data files by carrying physical media (e.g., jump drives) between computers.

  • Peer-to-Peer Network: Workgroup where connected computers share equal privileges without a centralized authority. Unsuited for large enterprise networks.

  • LAN: Local Area Network.

  • Client-Server Architecture:

    • Server: Centralized specialized computer providing dedicated resources to network hosts.

    • Client: End-user workstation requesting and consuming server resources.

    • Server Responsibilities: Printing, Login authentication, Permanent data storage, Website management, Communication services.

  • Internet Infrastructure:

    • Historical Roots: Originated during the Cold War to engineer a decentralized communication network robust against severe infrastructure damage.

    • Intranet: Private, internal network consisting of interconnected local area networks.

    • ISP: Internet Service Provider.

    • Graphical Representation: Internet infrastructure is represented visually in network topology diagrams using a cloud symbol.

Practice Questions and Review

Questions

  1. What is the Exposure Equation?

  2. What three things are computers better at than humans?

  3. What type of AI exists today?

  4. What does a 1 represent in computer science?

  5. What does a 0 represent?

  6. What is a bit?

  7. How many bits are in one byte?

  8. What was the first electronic general-purpose computer?

  9. About how many vacuum tubes did ENIAC have?

  10. What is the difference between ROM and RAM?

  11. What does CPU stand for?

  12. What is the motherboard?

  13. What are microchips made from?

  14. What is the difference between analog and digital?

  15. What is computer hardware?

  16. What is application software?

  17. What is system software?

  18. What is a program?

  19. What is coding?

  20. What are the five programming steps in order?

  21. Who wrote the first compiler?

  22. What does a low-level language use?

  23. What does a high-level language use?

  24. What does a very-high-level language use?

  25. What is the difference between a compiler and an interpreter?

  26. Who was FORTRAN designed for?

  27. Who was COBOL designed for?

  28. What does OOP stand for?

  29. What language is used by web browsers?

  30. Does Python use a compiler or interpreter?

  31. What does LAN stand for?

  32. What is a server?

  33. What is a client?

  34. What five services can a server provide?

  35. During what historical period did the Internet originate?

  36. What is an intranet?

  37. What does ISP stand for?

  38. What symbol represents the Internet in a network diagram?

  39. What is the Windows equivalent of the Mac Dock?

  40. What is the Mac equivalent of a Windows Shortcut?

  41. Why must a USB drive be ejected before removing it?

  42. What is the difference between copying and downloading?

  43. What is the definition of upload?

  44. What is the definition of install?

  45. What does FTP stand for?

  46. What are default settings?

  47. Are filename extensions visible by default?

  48. What was This PC formerly called?

  49. What letter represents the Windows hard drive?

  50. What is the Mac equivalent of This PC?

  51. Why is py.exe renamed python.exe?

  52. Why does Java need to be installed for jGRASP?

  53. Does jGRASP work only with Python?

Answers

  1. Bewilderment+Exposure=Obvious\text{Bewilderment} + \text{Exposure} = \text{Obvious}

  2. Faster, more accurate, do not forget.

  3. Artificial Narrow Intelligence (ANI).

  4. ON state.

  5. OFF state.

  6. A binary digit.

  7. 8 bits.

  8. ENIAC.

  9. Over 17,000 vacuum tubes.

  10. ROM is permanent memory; RAM is temporary memory.

  11. Central Processing Unit.

  12. The primary circuit board holding core computer components.

  13. Silicon.

  14. Analog measures continuously; digital creates precise, exact copies of original data.

  15. Physical equipment that can be seen or touched.

  16. Software designed to execute specific tasks for the user.

  17. Software required for the computer to operate properly.

  18. A sequence of instructions enabling a computer to perform a desired task.

  19. Physically typing instructions into a computer system.

  20. IdentifyPlanCodeTest/DebugUpdate\text{Identify} \rightarrow \text{Plan} \rightarrow \text{Code} \rightarrow \text{Test/Debug} \rightarrow \text{Update}

  21. Grace Hopper.

  22. 1s and 0s.

  23. English words and explicit commands.

  24. Pictures and graphical interfaces.

  25. A compiler translates the whole program before execution; an interpreter translates one statement at a time during execution.

  26. Scientists, mathematicians, and engineers.

  27. The business community.

  28. Object Oriented Programming.

  29. HTML.

  30. Interpreter.

  31. Local Area Network.

  32. A specialized computer that provides network services across a network.

  33. A computer that requests and receives services from a server.

  34. Printing, login authentication, permanent data storage, website management, and communication.

  35. The Cold War.

  36. A series of connected LANs functioning as a larger internal network.

  37. Internet Service Provider.

  38. A cloud symbol.

  39. Taskbar.

  40. Alias.

  41. Improper removal can corrupt or damage saved files.

  42. Copying transfers files from local physical media; downloading receives files from a remote server.

  43. Sending files from a local machine to a remote server.

  44. Writing required configuration and binary files to designated hard drive locations so software operates properly.

  45. File Transfer Protocol.

  46. Factory configuration parameters present prior to user customization.

  47. No, filename extensions are hidden by default.

  48. My Computer or Computer.

  49. C:

  50. Finder.

  51. jGRASP expects the executable file name to be python.exe.

  52. jGRASP is written in Java and requires the Java runtime environment to operate.

  53. No, jGRASP supports multiple programming languages.