AP Computer Science Principles Exam
Questions with Verified Answers
OverflowA-ACORRECTAANSWERSA-
errorAthatAresultsAwhenAtheAnumberAofAbitsAisAnotAenoughAtoAholdAtheAnumber,AlikeAaAcar'sA
odometerA"rollingAover"
Round-offA-ACORRECTAANSWERSA-
errorAthatAresultsAwhenAtheAnumberAofAbitsAisAnotAenoughAtoArepresentAtheAactualAnumber,A
likeA3AdigitsAtoArepresentAπAasA3.14
LossyA-ACORRECTAANSWERSA-
CompressingAdataAinAaAwayAthatAthrowsAsomeAdataAawayAandAmakesAitAalmostAimpossible
AtoArecoverAtheAoriginal,AgreatAcompression,AlikeAJPEGAimages
LosslessA-ACORRECTAANSWERSA-
CompressingAdataAinAaAwayAthatApreservesAallAdataAawayAandAallowsAfullArecoveryAofAtheA
original,AgoodAcompressionA--AusuallyAnotAasAgoodAasAlossy,AlikeAPNGAimages
MetadataA-ACORRECTAANSWERSA-
dataAaboutAdata,AlikeAaAcameraAstoringAtheAlocation,Aaperture,AshutterAspeed,Aetc.AforAaAdi
gitalAphoto
SequencingA-ACORRECTAANSWERSA-
codeAflowsAlineAbyAline,AoneAafterAanother,AlikeAaArecipe
SelectionA-ACORRECTAANSWERSA-
aAbooleanAconditionAtoAdetermineAwhichAofAtwoAalgorithmicApathsAareAtaken,AakaAif-then
IterationA-ACORRECTAANSWERSA-
usingAaAloopingAcontrolAstructure,AlikeAwhile,Afor,Aforeach,Arepeat,Arepeat-until,Aetc.
ReasonableATimeA-ACORRECTAANSWERSA-
polynomialAinAtheAnumberAofAstepsAanAalgorithmAtakesAinAtheAworstAcaseAbasedAonAtheAinp
utAsize
NotAreasonableAtimeA-ACORRECTAANSWERSA-
UsuallyAexponentialAinAtheAnumberAofAsteps,AlikeAdoublingAeveryAtimeAyourAinputAgrowsAby
Aone
HeuristicA-ACORRECTAANSWERSA-
usingAaA"rule"AtoAguideAanAalgorithm,AlikeAalwaysAwalkingAtowardAtheAnorthAstarAifAyouAwer
eAstuckAinAaAforest
UndecidableA-ACORRECTAANSWERSA-
AAproblemAthatAisAsoAdifficult,AweAcan'tAeverAcreateAanAalgorithmAthatAwouldAbeAableAtoAans
werAyesAorAnoAforAallAinputs,AlikeAdeterminingAifAaAuser'sAprogramArunAonAsomeAinputAwould
AalwaysAstopAandAnotArunAforever
LinearASearchA-ACORRECTAANSWERSA-
GoingAoneAbyAoneAvsAstartingAinAtheAmiddleAandAgoingAleft/rightAlikeAlookingAforAaAwordAinAt
heAdictionary
BinaryASearchA-ACORRECTAANSWERSA-
requiresAtheAlistAtoAbeAsortedAinAorderAandAthenAcuttingAtheAlistAinAhalf
APIsA-ACORRECTAANSWERSA-ApplicationAProgrammingAInterface
, CitizenAScienceA-ACORRECTAANSWERSA-
LotsAofApeopleAtoAhelpAwithAaAscientificAproject,AlikeAaskingAeveryoneAaroundAtheAworldAtoA
countAtheAbutterfliesAtheyAseeAoneAday
CloudAComputingA-ACORRECTAANSWERSA-
UsingAdistributedAcalculationsAand/orAstorageAforAbigAdataAorAaAwebAapplication
CrowdsourcingA-ACORRECTAANSWERSA-
AskingAlotsAofAusersAonlineAtoAhelpAwithAsomething,AlikeAfundingAaAproject,AorArunningASET
I@HomeAtoAhelpAlookAforAextraterrestrialAsignals
CreativeACommonsA-ACORRECTAANSWERSA-
AnAalternativeAtoAcopyrightAthatAallowsApeopleAtoAdeclareAhowAtheyAwantAtheirAartisticAcrea
tionsAtoAbeAshared,Aremixed,AusedAinAnoncommercialAcontexts,AandAhowAtheApolicyAshould
ApropagateAwithAremixedAversions
OpenAAccessA-ACORRECTAANSWERSA-
AApolicyAthatAallowsApeopleAtoAhaveAreadAaccessAtoAthings,Ae.g.,AlibrariesAorAonlineAdata
Moore'sALawA-ACORRECTAANSWERSA-
TheA#AofAtransistorsAonAaAchipAdoublesAeveryAtwoAyears
Peer-to-peerANetworksA-ACORRECTAANSWERSA-
AAsystemAwhereAoneAuser'sAcomputerAconnectsAthroughAtheAInternetAtoAanotherAuser'sAco
mputerAwithoutAgoingAthroughAanAintermediaryA"centralized"AcomputerAtoAmanageAtheAcon
nection
DigitalADivideA-ACORRECTAANSWERSA-
TheAideaAthatAsomeAcommunitiesA/ApopulationsAhaveAlessAaccessAtoAcomputingAthanAothe
rs
ISPA-ACORRECTAANSWERSA-InternetAServiceAProvider
HowAdoesAinternetAcommunicationAarriveAatAitsAdestination?A-ACORRECTAANSWERSA-
SpeechAonAtheAInternetAgoesAfromAtheAsourceAtoAanAISP,AintoAtheAcloud,AoutAofAtheAcloudAt
oAanotherAISP,AandAtoAitsAdestination
HowAcanAtheAgovernmentAcontrolAspeechAonAtheAInternet?A-ACORRECTAANSWERSA-
1)AItAcanAtryAtoAcontrolAtheAspeakerAorAtheAspeaker'sAISP,AbyAcriminalizingAcertainAkindsAofA
speech.AButAthatAwon'tAworkAifAtheAspeakerAisn'tAinAtheAsameAcountryAasAtheAlistener.A
2)ItAcanAtryAtoAcontrolAtheAlistener,AbyAprohibitingApossessionAofAcertainAkindsAofAmaterials.
AInAtheAU.S.,ApossessionAofAcopyrightedAsoftwareAwithoutAanAappropriateAlicenseAisAillegal,
AasAisApossessionAofAotherAcopyrightedAmaterialAwithAtheAintentAtoAprofitAfromAredistributing
Ait.A
3)ATheAgovernmentAcanAtryAtoAcontrolAtheAintermediaries.
HowAcanAInternetApostersAevadedAbeingAconvictedAforAdefamation/slanderAonAtheAWeb?A-
ACORRECTAANSWERSA-
TheApostersAcouldAevadeAresponsibilityAasAlongAasAtheyAremainedAanonymous,AasAtheyAe
asilyAcouldAonAtheAInternet.
WhatAhasACongressAgivenAISPsArelatingAtoAanAInternetADefamationAcase?A-
ACORRECTAANSWERSA-
CongressAhadAgivenAtheAISPsAaAcompleteAwaiverAofAresponsibilityAforAtheAconsequencesA
ofAfalseAandAdamag-AingAstatements,AevenAwhenAtheAISPAknewAtheyAwereAfalse.
InternetAProtocolAHourglassA-ACORRECTAANSWERSA-
EachAprotocolAinterfacesAonlyAtoAthoseAinAtheAlayersAimmediatelyAaboveAandAbelowAit,Aand
Questions with Verified Answers
OverflowA-ACORRECTAANSWERSA-
errorAthatAresultsAwhenAtheAnumberAofAbitsAisAnotAenoughAtoAholdAtheAnumber,AlikeAaAcar'sA
odometerA"rollingAover"
Round-offA-ACORRECTAANSWERSA-
errorAthatAresultsAwhenAtheAnumberAofAbitsAisAnotAenoughAtoArepresentAtheAactualAnumber,A
likeA3AdigitsAtoArepresentAπAasA3.14
LossyA-ACORRECTAANSWERSA-
CompressingAdataAinAaAwayAthatAthrowsAsomeAdataAawayAandAmakesAitAalmostAimpossible
AtoArecoverAtheAoriginal,AgreatAcompression,AlikeAJPEGAimages
LosslessA-ACORRECTAANSWERSA-
CompressingAdataAinAaAwayAthatApreservesAallAdataAawayAandAallowsAfullArecoveryAofAtheA
original,AgoodAcompressionA--AusuallyAnotAasAgoodAasAlossy,AlikeAPNGAimages
MetadataA-ACORRECTAANSWERSA-
dataAaboutAdata,AlikeAaAcameraAstoringAtheAlocation,Aaperture,AshutterAspeed,Aetc.AforAaAdi
gitalAphoto
SequencingA-ACORRECTAANSWERSA-
codeAflowsAlineAbyAline,AoneAafterAanother,AlikeAaArecipe
SelectionA-ACORRECTAANSWERSA-
aAbooleanAconditionAtoAdetermineAwhichAofAtwoAalgorithmicApathsAareAtaken,AakaAif-then
IterationA-ACORRECTAANSWERSA-
usingAaAloopingAcontrolAstructure,AlikeAwhile,Afor,Aforeach,Arepeat,Arepeat-until,Aetc.
ReasonableATimeA-ACORRECTAANSWERSA-
polynomialAinAtheAnumberAofAstepsAanAalgorithmAtakesAinAtheAworstAcaseAbasedAonAtheAinp
utAsize
NotAreasonableAtimeA-ACORRECTAANSWERSA-
UsuallyAexponentialAinAtheAnumberAofAsteps,AlikeAdoublingAeveryAtimeAyourAinputAgrowsAby
Aone
HeuristicA-ACORRECTAANSWERSA-
usingAaA"rule"AtoAguideAanAalgorithm,AlikeAalwaysAwalkingAtowardAtheAnorthAstarAifAyouAwer
eAstuckAinAaAforest
UndecidableA-ACORRECTAANSWERSA-
AAproblemAthatAisAsoAdifficult,AweAcan'tAeverAcreateAanAalgorithmAthatAwouldAbeAableAtoAans
werAyesAorAnoAforAallAinputs,AlikeAdeterminingAifAaAuser'sAprogramArunAonAsomeAinputAwould
AalwaysAstopAandAnotArunAforever
LinearASearchA-ACORRECTAANSWERSA-
GoingAoneAbyAoneAvsAstartingAinAtheAmiddleAandAgoingAleft/rightAlikeAlookingAforAaAwordAinAt
heAdictionary
BinaryASearchA-ACORRECTAANSWERSA-
requiresAtheAlistAtoAbeAsortedAinAorderAandAthenAcuttingAtheAlistAinAhalf
APIsA-ACORRECTAANSWERSA-ApplicationAProgrammingAInterface
, CitizenAScienceA-ACORRECTAANSWERSA-
LotsAofApeopleAtoAhelpAwithAaAscientificAproject,AlikeAaskingAeveryoneAaroundAtheAworldAtoA
countAtheAbutterfliesAtheyAseeAoneAday
CloudAComputingA-ACORRECTAANSWERSA-
UsingAdistributedAcalculationsAand/orAstorageAforAbigAdataAorAaAwebAapplication
CrowdsourcingA-ACORRECTAANSWERSA-
AskingAlotsAofAusersAonlineAtoAhelpAwithAsomething,AlikeAfundingAaAproject,AorArunningASET
I@HomeAtoAhelpAlookAforAextraterrestrialAsignals
CreativeACommonsA-ACORRECTAANSWERSA-
AnAalternativeAtoAcopyrightAthatAallowsApeopleAtoAdeclareAhowAtheyAwantAtheirAartisticAcrea
tionsAtoAbeAshared,Aremixed,AusedAinAnoncommercialAcontexts,AandAhowAtheApolicyAshould
ApropagateAwithAremixedAversions
OpenAAccessA-ACORRECTAANSWERSA-
AApolicyAthatAallowsApeopleAtoAhaveAreadAaccessAtoAthings,Ae.g.,AlibrariesAorAonlineAdata
Moore'sALawA-ACORRECTAANSWERSA-
TheA#AofAtransistorsAonAaAchipAdoublesAeveryAtwoAyears
Peer-to-peerANetworksA-ACORRECTAANSWERSA-
AAsystemAwhereAoneAuser'sAcomputerAconnectsAthroughAtheAInternetAtoAanotherAuser'sAco
mputerAwithoutAgoingAthroughAanAintermediaryA"centralized"AcomputerAtoAmanageAtheAcon
nection
DigitalADivideA-ACORRECTAANSWERSA-
TheAideaAthatAsomeAcommunitiesA/ApopulationsAhaveAlessAaccessAtoAcomputingAthanAothe
rs
ISPA-ACORRECTAANSWERSA-InternetAServiceAProvider
HowAdoesAinternetAcommunicationAarriveAatAitsAdestination?A-ACORRECTAANSWERSA-
SpeechAonAtheAInternetAgoesAfromAtheAsourceAtoAanAISP,AintoAtheAcloud,AoutAofAtheAcloudAt
oAanotherAISP,AandAtoAitsAdestination
HowAcanAtheAgovernmentAcontrolAspeechAonAtheAInternet?A-ACORRECTAANSWERSA-
1)AItAcanAtryAtoAcontrolAtheAspeakerAorAtheAspeaker'sAISP,AbyAcriminalizingAcertainAkindsAofA
speech.AButAthatAwon'tAworkAifAtheAspeakerAisn'tAinAtheAsameAcountryAasAtheAlistener.A
2)ItAcanAtryAtoAcontrolAtheAlistener,AbyAprohibitingApossessionAofAcertainAkindsAofAmaterials.
AInAtheAU.S.,ApossessionAofAcopyrightedAsoftwareAwithoutAanAappropriateAlicenseAisAillegal,
AasAisApossessionAofAotherAcopyrightedAmaterialAwithAtheAintentAtoAprofitAfromAredistributing
Ait.A
3)ATheAgovernmentAcanAtryAtoAcontrolAtheAintermediaries.
HowAcanAInternetApostersAevadedAbeingAconvictedAforAdefamation/slanderAonAtheAWeb?A-
ACORRECTAANSWERSA-
TheApostersAcouldAevadeAresponsibilityAasAlongAasAtheyAremainedAanonymous,AasAtheyAe
asilyAcouldAonAtheAInternet.
WhatAhasACongressAgivenAISPsArelatingAtoAanAInternetADefamationAcase?A-
ACORRECTAANSWERSA-
CongressAhadAgivenAtheAISPsAaAcompleteAwaiverAofAresponsibilityAforAtheAconsequencesA
ofAfalseAandAdamag-AingAstatements,AevenAwhenAtheAISPAknewAtheyAwereAfalse.
InternetAProtocolAHourglassA-ACORRECTAANSWERSA-
EachAprotocolAinterfacesAonlyAtoAthoseAinAtheAlayersAimmediatelyAaboveAandAbelowAit,Aand