Docsity

AP Computer Science Principles Exam Topics, Exams of Computer Science

Toggle sidebar
bg1
AP Computer Science Principles
EXAMination test
1. Overflow - Correct answer error that results when the number of bits is not
enough to hold the number, like a car's odometer "rolling over"
2. Round-off - Correct answer error that results when the number of bits is not
enough to represent the actual number, like 3 digits to represent π as 3.14
3. Lossy - Correct answer Compressing data in a way that throws some data away
and makes it almost impossible to recover the original, great compression, like
JPEG images
4. Lossless - Correct answer Compressing data in a way that preserves all data
away and allows full recovery of the original, good compression -- usually not as
good as lossy, like PNG images
5. Metadata - Correct answer data about data, like a camera storing the location,
aperture, shutter speed, etc. for a digital photo
6. Sequencing - Correct answer code flows line by line, one after another, like a
recipe
7. Selection - Correct answer a boolean condition to determine which of two
algorithmic paths are taken, aka if-then
8. Iteration - Correct answer using a looping control structure, like while, for,
foreach, repeat, repeat-until, etc.
9. Reasonable Time - Correct answer polynomial in the number of steps an
algorithm takes in the worst case based on the input size
10.Not reasonable time - Correct answer Usually exponential in the number of
steps, like doubling every time your input grows by one
11.Heuristic - Correct answer using a "rule" to guide an algorithm, like always
walking toward the north star if you were stuck in a forest
12.Undecidable - Correct answer A problem that is so difficult, we can't ever create
an algorithm that would be able to answer yes or no for all inputs, like
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe

Partial preview of the text

Download AP Computer Science Principles Exam Topics and more Exams Computer Science in PDF only on Docsity!

AP Computer Science Principles

EXAMination test

  1. Overflow - Correct answer error that results when the number of bits is not enough to hold the number, like a car's odometer "rolling over"
  2. Round-off - Correct answer error that results when the number of bits is not enough to represent the actual number, like 3 digits to represent π as 3.
  3. Lossy - Correct answer Compressing data in a way that throws some data away and makes it almost impossible to recover the original, great compression, like JPEG images
  4. Lossless - Correct answer Compressing data in a way that preserves all data away and allows full recovery of the original, good compression -- usually not as good as lossy, like PNG images
  5. Metadata - Correct answer data about data, like a camera storing the location, aperture, shutter speed, etc. for a digital photo
  6. Sequencing - Correct answer code flows line by line, one after another, like a recipe
  7. Selection - Correct answer a boolean condition to determine which of two algorithmic paths are taken, aka if-then
  8. Iteration - Correct answer using a looping control structure, like while, for, foreach, repeat, repeat-until, etc.
  9. Reasonable Time - Correct answer polynomial in the number of steps an algorithm takes in the worst case based on the input size
  10. Not reasonable time - Correct answer Usually exponential in the number of steps, like doubling every time your input grows by one
  11. Heuristic - Correct answer using a "rule" to guide an algorithm, like always walking toward the north star if you were stuck in a forest
  12. Undecidable - Correct answer A problem that is so difficult, we can't ever create an algorithm that would be able to answer yes or no for all inputs, like

determining if a user's program run on some input would always stop and not run forever

  1. Linear Search - Correct answer Going one by one vs starting in the middle and going left/right like looking for a word in the dictionary
  2. Binary Search - Correct answer requires the list to be sorted in order and then cutting the list in half
  3. APIs - Correct answer Application Programming Interface
  4. Citizen Science - Correct answer Lots of people to help with a scientific project, like asking everyone around the world to count the butterflies they see one day
  5. Cloud Computing - Correct answer Using distributed calculations and/or storage for big data or a web application
  6. Crowdsourcing - Correct answer Asking lots of users online to help with something, like funding a project, or running SETI@Home to help look for extraterrestrial signals
  7. Creative Commons - Correct answer An alternative to copyright that allows people to declare how they want their artistic creations to be shared, remixed, used in noncommercial contexts, and how the policy should propagate with remixed versions
  8. Open Access - Correct answer A policy that allows people to have read access to things, e.g., libraries or online data
  9. Moore's Law - Correct answer The # of transistors on a chip doubles every two years
  10. Peer-to-peer Networks - Correct answer A system where one user's computer connects through the Internet to another user's computer without going through an intermediary "centralized" computer to manage the connection
  11. Digital Divide - Correct answer The idea that some communities / populations have less access to computing than others
  12. ISP - Correct answer Internet Service Provider
  13. How does internet communication arrive at its destination? - Correct answer Speech on the Internet goes from the source to an ISP, into the cloud, out of the cloud to another ISP, and to its destination

network should be dumb—optimized to carry out their single limited function of passing packets.

  1. RFC - Correct answer Request for Comment
  2. Standards adopted through a remarkable process of consensus- building, nonhierarchical in the extreme. Someone posts a proposal, and a cycle of comment and revision, of buy-in and objection, eventually converges on something useful, if not universally regarded as perfect.
  3. Shortcut for going from binary to hexadecimal - Correct answer To translate a binary numeral (like 11010111012) to hexadecimal, start by splitting it into groups of four bits, from right-to-left (like this: 11 0101 1101).
  4. Then determine the value of each group and write the corresponding hex digit.
  5. Internet - Correct answer A network of independent but connected devices all over the world.
  6. World Wide Web - Correct answer The collection of interlinked website documents (such as HTML files) that you can view with a web browser by typing addresses like http://bjc.berkeley.edu/website/privacy.html.
  7. HTML - Correct answer Hypertext markup language
  8. Most web pages are written with ________
  9. URL - Correct answer Uniform Resource Locator
  10. An address for accessing specific web data located on a server
  11. Server - Correct answer A computer hosting data for others to access
  12. Protocol - Correct answer the standard for communication between browsers and servers (usually "http" or "https")
  13. Sometimes not visible in browsers like Google Chrome
  14. Domain Name - Correct answer The name of the server that hosts the data
  15. (bjc.berkeley.edu)
  16. Path - Correct answer the location of the data in a hierarchy of folders on the server
  17. (Website/privacy.html)
  18. Protocols - Correct answer Standards for communication
  19. IP - Correct answer Internet Protocol
  20. An addressing system that finds paths to distant computers
  21. Specifies how a router handles a request for another IP address.
  1. Redundant - Correct answer There are multiple pathways among the physical connections of the Internet to create redundancy. Even if one pathway is unavailable, there is still another way to transmit a message from sender to receiver
  2. Hiearchial - Correct answer There are two ____________ Internet addressing systems, domain names and IP addresses. These address ______________ works much like the postal system, which locates people first by state, then city, then street, then house number, then apartment, and then finally person.
  3. Fault Tolerance - Correct answer ability to work around problems
  4. Scalability - Correct answer the ability of the net to keep working even as the size of the network and the amount of traffic over the network increase.
  5. Virus - Correct answer A kind of malware that tries to spread itself over the network to other computers.
  6. Antivirus Software - Correct answer Helps protect against virus attacks
  7. Phishing - Correct answer An attacker sends you an email that appears to be from some official organization (such as your bank) and tricks you into giving information to the attackers (such as your bank password).
  8. DDoS - Correct answer Distributed Denial of Service
  9. -Consists of sending a lot of requests to a server at the same time. This can overload the server's network bandwidth.
  10. -Causes a temporary inability to reach the targeted server so other users of that server are denied service.
  11. Which protocols are used to keep secure HTTP connections? - Correct answer Transport Layer Security (TLS) or maybe an older version called Secure Sockets Layer (SSL)
  12. With these protocols, the site you are visiting sends its public key, and your browser uses it to encrypt the information you send.
  13. Certificate Authorities - Correct answer Used by many websites for encryption to protect files and information that is transmitted over the Internet. They issue certificates to verify the identity of a user or computer.
  14. Public IP Address - Correct answer The IP address that is logged by various servers/devices when you connect to them through your internet connection.

network even though the physical reality on the lower level is one of many tiny subnetworks.

  1. Network Interface Hardware - Correct answer Also known as Link Layer
  2. All Internet devices connect through a physical interface that uses a protocol to manage the connection to the local network. These local protocols are the least abstract because they deal directly with your physical hardware.
  3. DNS - Correct answer Domain Name System
  4. The hierarchical addressing protocol that is human-readable
  5. Who is in charge of the Internet? - Correct answer The computers on the Internet and the connections among them don't belong to any one organization.
  6. ICANN - Correct answer the Internet Corporation for Assigned Names and Numbers
  7. Controls the DNS hierarchy and the allocation of IP addresses.
  8. For how long has the U.S. dominated the Internet and why? - Correct answer The U.S. has "controlled" the Internet up until 2009. The Advanced Research Project Agency (ARPA) first developed the Internet in 1969.
  9. Open Protocols - Correct answer Standards that are not owned by a company
  10. IETF - Correct answer (The Internet Engineering Task Force) and the Internet Society oversee Internet protocols
  11. What does the Internet rely on to operate properly? - Correct answer The internet relies on the cooperation of many different elements.
  12. Firewall - Correct answer Used to limit the kinds of connections (HTTP requests, incoming mail, etc.) outsiders can make to your computer.
  13. Cipher - Correct answer The set of rules you are using to encode the information
  14. Key - Correct answer What tells you how to arrange the cipher's rules. _______ is applied using an algorithm to a string or block of unencrypted text to produce encrypted.
  15. Deciphering - Correct answer Analyzing the code and working back from it
  16. Monoalphabetic Cipher - Correct answer A class of ciphers where the code is based on one letter of the alphabet standing for another letter consistently throughout the message
  1. Brute force - Correct answer Trying all the possible ways to crack a code
  2. Frequency Analysis - Correct answer Based on the idea that every language has its own specific patterns. The study of the frequency of letters or groups of letters in a ciphertext.
  3. Crib - Correct answer Words, letters, and phrases that are so common that it is hard to form a sentence without them
  4. Examples: e and the
  5. Polyalphabetic Cipher - Correct answer The way you scramble the alphabet actually changes throughout the message
  6. Example: Vigenère cipher
  7. Vigenère Square - Correct answer Alphabet goes up on the top and also to the side in order to help write a code.
  8. How can you crack Vigenère cipher? - Correct answer By using a type of frequency analysis developed by Charles Babbage. Babbage realized that some patterns in a long message may still show up and he counted how many letters separated those repeated patterns.
  9. One time pad encryption - Correct answer Only way to create an unbreakable cipher. Uses the key that is as long as the message itself. Once a sheet is used for a message you destroy it. Then you use the next sheet for the next message so you never repeat a key. As long as you keep the pad safe, no one can ever decrypt the message.
  10. The Enigma Machine - Correct answer An example of a one time pad encryption device.
  11. The British Bombe - Correct answer Device developed by Alan Turing used by the British military to crack the enigma machine. As long as this device knew 20 characters of the message it could crack the code.
  12. Prime number - Correct answer Numbers only divisible by themselves and one. Very useful for internet security because of this trait.
  13. Public Key - Correct answer A code that is available for anyone to use.
  14. Private Key - Correct answer A code that must remain confidential to its respective owner.
  15. How does Public Key/Private Key Cryptography work? - Correct answer Example: If Bob wants to send sensitive data to Alice, and wants to be sure that
  1. How does the Diffie-Hellman-Merkle Method work? - Correct answer In Diffie-Hellman, Alice and Bob make the shared secret key, online, together, in full view of any other eavesdropper. The breakthrough allows Alice and Bob to openly exchange some Diffie-Hellman numbers. In private, they use each other's DH numbers, their secret random numbers, and the DH method to agree on the same secret key. Although the eavesdropper knows the DH method and copies Alice and Bob's conversation, he cannot figure out Alice and Bob's agreed-on secret key.
  2. What are some problems of the Diffie-Hellman-Merkle Method? - Correct answer 1) Lack of authentication
    1. Failing to provide a versatile means for secret key exchange.
  3. Caesar Cipher - Correct answer Also known as a shift cipher, is one of the simplest forms of encryption. It is a substitution cipher where each letter in the original message (called the plaintext) is replaced with a letter corresponding to a certain number of letters up or down in the alphabet.
  4. AND - Correct answer a Boolean operator. Both have to be true in order for it to evaluate to true.
  5. OR - Correct answer a Boolean operator. one or the other has to be true in order for it to evaluate to true.
  6. NOT - Correct answer a Boolean operator. Everything except the entered input is true.
  7. Boolean Expression - Correct answer an expression that results in a __________ value, that is, in a value of either true or false.
  8. Composition of Functions - Correct answer An act or mechanism to combine simple functions to build more complicated ones.
  9. Conditional Statement - Correct answer Set of rules performed if a certain condition is met.
  10. Data Type - Correct answer A classification of data which tells the compiler or interpreter how the programmer intends to use the data. Examples include : real, integer, float (decimal point number)
  11. Debugging - Correct answer A multi-step process that involves identifying a problem, isolating the source of the problem, and then either correcting the problem or determining a way to work around it. The final step of ______________ is to test the correction or workaround and make sure it works.
  1. Default Value - Correct answer What the code is set to when it is started.
  2. If () Clause - Correct answer Keep Checking:
  3. If this is true
  4. Then do this
  5. If ()... Else Clause - Correct answer Keep Checking:
  6. If this is true...
  7. then do this 157.... and if it is not true
  8. then do this
  9. Input Type - Correct answer Set up different variables to take a specific ______ _______.
  10. Lists - Correct answer Reports a newly created _________ with the given items.
  11. The _______ items can be anything: text, numbers, blocks, scripts, and even other ______.
  12. Mathematical expression - Correct answer Numbers, symbols and operators (such as + and ×) grouped together that show the value of something.
  13. Nested IFs - Correct answer If you need to test for more than one condition, then take one of several actions, depending on the result of the tests, you can nest multiple IF statements together in one formula.
  14. Predicate - Correct answer A ________ is a special kind of reporter that always reports true or false. ________ have a hexagonal shape. The special shape is a reminder that ______________ don't generally make sense in an input slot of blocks that are expecting a number or text.
  15. Reporter block - Correct answer Has an oval shape. It is called a " ______ " because when it's run, instead of carrying out an action, it reports a value that can be used as an input to another block.
  16. Predicate block - Correct answer A ________ is a special kind of reporter that always reports true or false. ________ have a hexagonal shape. The special shape is a reminder that predicates don't generally make sense in an input slot of blocks that are expecting a number or text.
  17. Script variable - Correct answer Used when you only need a variable temporarily, during the running of a particular script. You can use ____ ________ block to make the variable. Example : for loop, the (length) only works inside the for loop.
  1. Join words () > - Correct answer An Operators block and a Reporter block. The block concatenates, or "links" the two values together and reports the result
  2. Example : print "This is my" + " " + variable + " " + "class."
  3. Not () - Correct answer an Operators block and a Boolean block. The block checks if the boolean inside it is false — if it is false, the block returns true; if the condition is true, it returns false.
  4. Report () - Correct answer Reporters that report Boolean (true or false) values.
  5. Script Variables - Correct answer Used when you only need a variable temporarily, during the running of a particular script. You can use ____ ________ block to make the variable.
  6. Set (variable name) to (value) - Correct answer Variables block and a Stack block. The block will set the specified variable to the given value: a string or number.
  7. Example : Set (score) to (0)
  8. Touching ()? - Correct answer A Sensing block and a Boolean block. The block checks if its sprite is touching the mouse-pointer, edge, or another sprite (a Reporter block holding the sprite's name can be used). If the sprite is touching the selected object, the block returns true; if it is not, it returns false.
  9. TRUE - Correct answer reported input is true
  10. Unicode () as letter - Correct answer Reports the letter with a given code.
  11. Letters and other characters are represented inside the computer using a numeric code called Unicode. Unicode can represent the characters of all human languages, plus many non-letter symbols.
  12. Unicode of () - Correct answer Reports the Unicode value of a letter.
  13. Letters and other characters are represented inside the computer using a numeric code called Unicode. Type or paste a single character into the input to get its Unicode number.
  14. T and T equals - Correct answer T
  15. T and F equals - Correct answer F
  16. F and T equals - Correct answer F
  17. F and F equals - Correct answer F
  1. T or T equals - Correct answer T
  2. T or F equals - Correct answer T
  3. F or T equals - Correct answer T
  4. F or F equals - Correct answer F
  5. Why is the use of variables, script variables, and input variables important? - Correct answer Because important information can be maintained and referenced. They can symbolically represent anything from numbers to words which can be helpful when programming in Snap.
  6. Why is abstraction important? - Correct answer It eliminates the details and condenses it down to one line of code.
  7. Why is it useful to specify the type of input that a block is expected to receive? - Correct answer So the function does not result in an error or does not work in the way the user intended it.
  8. Logical Error or Semantic Error - Correct answer You are not logically setting up the program to process correctly.
  9. Algorithim - Correct answer A standard way to perform an operation.
  10. Tip for debugging code - Correct answer Put a wait after every command