版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認(rèn)領(lǐng)
文檔簡介
Python程序設(shè)計(英語)知到智慧樹期末考試答案題庫2025年中央財經(jīng)大學(xué)Withinamethoddefinition,theinstancevariablexcouldbeaccessedviawhichexpression?()
答案:self.xWiththefollowinginput,pleaseselectthecorrectoutputofPythonConsole()message=‘tcsndcontxe’message[5:8]+message[-1]+message[-2]+message[0]
答案:‘conext’Whichstringmethodconvertsallthecharactersofastringtouppercase?()
答案:upperWhichstringmethodconvertsallthecharactersofastringtolowercase?()
答案:lowerWhichoneistrueaboutthefunction?()
答案:Whenafunctiondefinitionhasseveralparameters,theactualparametersarematchedupwiththeformalparametersbyposition.WhichofthefollowingwasNOTaclassintheracquetballsimulation?()
答案:ScoreWhichofthefollowingstatementoutput5.0?()
答案:round(4.6)WhichofthefollowingmethodsispartoftheDieViewclassinthischapter?()
答案:setValueWhichofthefollowingmethodsisNOTpartoftheButtonclassinthischapter?()
答案:setLabelWhichofthefollowingmatchestype(1+2*3.14)?()
答案:Whichofthefollowingisthesameass[0:-1]?()
答案:s[:len(s)-1]WhichofthefollowingisNOToneofthefundamentalcharacteristicsofobject-orienteddesign/programming?()
答案:generalityWhichofthefollowingisnotavalidruleofBooleanalgebra?()
答案:not(aandb)==not(a)andnot(b)WhichofthefollowingisNOTastepinpuretop-downdesign?()
答案:ConstructasimplifiedprototypeofthesystemWhichofthefollowingisnotareasontousefunctions?()
答案:todemonstrateintellectualsuperiorityWhichofthefollowingisnotaPythonlistmethod?()
答案:getWhichofthefollowingisnotalegalidentifier?()
答案:spamWhichofthefollowingisNOTaguidelineforOOD?()
答案:Candidateobjectscanbefoundbylookingattheverbsinaproblemdescription.WhichofthefollowingisNOTadictionarymethod?()
答案:sortWhichofthefollowingisNOTacharacteristicofaPythonlist?()
答案:Itisimmutable.WhichofthefollowingisNOTabuilt-insequenceoperationinPython?()
答案:sortingWhichofthefollowingisnotabuilt-inPythondatatype?()
答案:rationalWhichofthefollowingisnotabuilt-inmethodofPython?()
答案:writelineWhichofthefollowinginformationisincludedinafunction’sinterface?()
答案:name;parameters;expectedreturnvaluesWhichofthefollowingexpressionscorrectlytestsifxiseven?()
答案:x%2==0Whichofthefollowingcomputesthehorizontaldistancebetweenpointsp1andp2?()
答案:abs(p1.getX()-p2.getX())Whichofthefollowingcannotbeusedtoconvertastringofdigitsintoanumber?()
答案:strWhichofthefollowingcanNOTbeexecuted?()
答案:a=(4,3,2,1),thena[1]=2Whichexpressionistrueapproximately66%ofthetime?()
答案:random()<0.66Wheremathematiciansusesubscripting,computerprogrammersuse()
答案:indexingWhenwritingtoafile,makesureyoudonotclobberanyfilesyouwillneedlater.()
答案:對Whenaprogramisbeingrundirectly(notimported),thevalueof__name__is()
答案:__main__Whatisthefundamentalquestionofcomputerscience?()
答案:Whatcanbecomputed?WhatisthedatatypeofserverinanRBallGame?()
答案:PlayerWhatdoes2representforinthefollowingstatement?()print("Thetotalvalueofyourchangeis${0:0.2f}".format(total))
答案:precisionWhatcoloriscolor_rgb(0,255,255)?()
答案:CyanUnlikestrings,Pythonlistsarenotmutable.()
答案:錯UnicodeusesthesamecodesasASCIIforthe125charactersoriginallydefined.()
答案:錯Typically,thedesignprocessinvolvesconsiderabletrialanderror.()
答案:對Typically,thedesignprocessinvolvesconsiderabletrialanderror.()
答案:對Top-downdesignisalsocalledstepwiserefinement.()
答案:對Thereisusuallyonlyonecorrectsolutiontoaprobleminvolvingdecisionstructures.()
答案:錯Thereisnodifferencebetweentwostringmethodss.capitalize()ands.title().()
答案:錯Therearemanydifferentlanguages,butallsharethepropertyofhavingaprecisesyntax(form)andsemantics(meaning).()
答案:對Thetermappliedtohidingdetailsinsideclassdefinitionsis()
答案:encapsulationThesituationwheretwovariablesrefertothesameobjectiscalledaliasing.()
答案:對ThesetValuemethodredefinedinColorDieViewclassisanexampleof()
答案:inheritance;polymorphismThescopeofavariableistheareaoftheprogramwhereitmaybereferenced.()
答案:對Theresultofstatementround(21.6)%6is3.0.()
答案:錯Theresultoflist(range(2,8,2))is()
答案:[2,4,6]Theprocessofdescribingexactlywhatacomputerprogramwilldotosolveaproblemiscalled()
答案:specificationThepatternusedtocomputefactorialsis()
答案:accumulatorTheparametersappearinginthefunctiondefinitionarecalledformalparameters,andtheexpressionsappearinginafunctioncallareknownasactualparameters.()
答案:對Theoutputofthefollowingstatementsis()frommathimportsqrtprint(sqrt(16)*3+1==13)
答案:TrueThemostappropriatedatatypeforstoringthevalueofpiis()
答案:floatThemethodthatallowsustoaccessinformationfromtheinstancevariablesofobjectiscalled().
答案:accessorThemethodthataddsasingleitemtotheendofalistis()
答案:appendTheliteralsfortypeboolare()
答案:True,FalseThelastcharacterofastringsisatpositionlen(s)-1.()
答案:對Theitemslistedintheparenthesesofafunctiondefinitionarecalled()
答案:bothBandCarecorrectTheitemsdictionarymethodreturnsa(n)()
答案:sequenceoftuplesTheinitialstripped-downversioniscalledaprototype.()
答案:對Thefloatvaluesarenotexact,whileintsalwaysare.()
答案:對ThefirstparameterofaPythonmethoddefinitioniscalledthis.()
答案:錯TheeasiestwaytoiteratethroughthelinesofafileinPythonistouseawhileloop.()
答案:錯Thecountedlooppatternusesadefiniteloop.()
答案:對Theconditionx<=y<=zisallowedinPython.()
答案:對Thebestwaytowriteaprogramistoimmediatelytypeinsomecodeandthendebugituntilitworks.()
答案:錯Thearrowsinamodulehierarchychartdepict()
答案:informationflowTakingthesquarerootofanegativevaluewithmath.sqrtproducesa(n)()
答案:ValueError;programcrashStandarddeviationmeasureshowspreadoutadatasetis.()
答案:對Spiraldevelopmentisanalternativetotop-downdesign.()
答案:錯Somemodules,whicharemadetobeimportedandusedbyotherprograms,arereferredtoasstand-aloneprograms.()
答案:錯Pythonpassesparametersbyvalue.()
答案:對Pythonautomaticallyconvertsnumbersfromonedatatypetoanotherincertainsituations.()
答案:對Placingadecisioninsideofanotherdecisionisanexampleof()
答案:nestingOnedifferencebetweenacompilerandinterpreteris()
答案:Acompilerprocessessourcecode.Newobjectsarecreatedbyinvokingaconstructor.()
答案:對Mutabletypessuchaslistsanddictionariescanserveaskeysbecausetheycanbehashed.()
答案:錯Multi-waydecisionsmustbehandledbynestingmultipleif-elsestatements.()
答案:錯Modifyingthelistwhileloopingthroughitcanproducestrangeanomalies.()
答案:對LiHuaforgothisQQpassword,buthestillrememberedthatthepasswordwastheASCIIcodecorrespondingtohisname“LiHua”.Whichofthefollowingisthecorrectone?()
答案:76105327211797Itemscanberemovedfromalistwiththedeloperator.()
答案:對Itisquitecommontocreateaclasswithmanysimplemethodsinwell-modularized,object-orientedprograms.()
答案:對Itisconsideredbadstyletodirectlyaccessaninstancevariableoutsideofaclassdefinition.()
答案:對Instancevariablesgoawayonceamethodterminates.()
答案:錯Intop-downdesign,thesubcomponentsofthedesignare()
答案:functionsIntheracquetballsimulation,whatdatatypeisreturnedbythegameOverfunction?()
答案:boolInPython,x=x+1isalegalstatement.()
答案:對InPython,thebodyofadecisionisindicatedby()
答案:indentationInPython,gettinguserinputisdonewithaspecialexpressioncalled()
答案:inputInPython,afunctioncanreturnonlyonevalue.()
答案:錯InPython,4+5producesthesameresulttypeas4.0+5.0.()
答案:錯InPython“4”+“5”is“45”.()
答案:對InaPythonclass,theconstructoriscalled__init__.()
答案:對Iftherewasnobareexceptattheendofatrystatementandnoneoftheexceptclausesmatch,theprogramwouldstillcrash.()
答案:對Ifthevaluebeingpassedisamutableobject,thenchangesmadetotheobjectmaybevisibletothecaller.()
答案:對Ifn=“nice”,t=”try”,whichofthefollowingoptionswillcauseanerror?()
答案:print([n+t][1])IdentifiersinPythonarenotcase-sensitive.()
答案:錯Identifiersarenames;theybeginwithanunderscoreorletterwhichcanbefollowedbyacombinationofletter,digit,orunderscorecharacters.()
答案:對Hidingthedetailsofanobjectinaclassdefinitioniscalledinstantiation.()
答案:錯Functionsthatdon'texplicitlyreturnavaluereturnthespecialobjectNull.()
答案:錯Fromadesignstandpoint,encapsulationseparatestheconcernsof()
答案:“what”vs.“how”Formalparametersandothervariablesinsidefunctiondefinitionsarelocaltothefunction.()
答案:對Findacorrectalgorithmtosolveaproblemandthenstrivefor()
答案:clarity;simplicity;efficiency;scalabilityDefiniteloopsareloopsthatexecuteaknownnumberoftimes.()
答案:對Computerscangeneratetrulyrandomnumbers.()
答案:錯Bydefault,thesplitmethodwillsplitthestringwhereveraspaceoccurs.()
答案:對Attheendofthefile,thereadline()returnsan“\n”.()
答案:錯Arraysareusuallyheterogeneous,butlistsarehomogeneous.()
答案:錯Anobjectmayhaveonlyoneinstancevariable.()
答案:錯Animportantconsiderationingraphicalprogrammingisthechoiceofanappropriatecoordinatesystem.()
答案:對Allinformationthatacomputeriscurrentlyworkingonisstoredinmainmemory.()
答案:對abs(3)=3.0()
答案:錯Atop-downdesignisbestimplementedfromthetopdown.()
答案:錯Astatementis()
答案:acompletecomputercommandAsinglepointonagraphicsscreeniscalledapixel.()
答案:對Asimulationthatusesprobabilisticeventsiscalled()
答案:MonteCarloAsimpledecisioncanbeimplementedwithanifstatement.()
答案:對Asentinelloopshouldnotactuallyprocessthesentinelvalue.()
答案:對Asentinelloopaskstheuserwhethertocontinueoneachiteration.()
答案:錯APythonwhileimplementsadefiniteloop.()
答案:錯APythonstringliteralcanspanmultiplelinesifenclosedwith()
答案:"""APythonfunctiondefinitionbeginswith()
答案:defAPythondictionaryisakindofsequence.()
答案:錯APythonconventionfordefiningmethodsthatare"private"toaclassistobeginthemethodnamewith()
答案:anunderscore(_)Apseudorandomnumbergeneratorworksbystartingwithaseedvalue.()
答案:對Amultiplechoicequestionismostsimilarto()
答案:multi-waydecisionsAmethodthatchangesthestateofanobjectiscalleda(n)()
答案:mutatorAmethoddefinitionwithfourformalparametersisgenerallycalledwithhowmanyactualparameters?()
答案:threeAmethoddefinitionissimilartoa(n)()
答案:functiondefinitionAloopthatneverterminatesiscalled()
答案:infiniteAloopstructurethatteststheloopconditionafterexecutingtheloopbodyiscalleda()
答案:post-testloopAlooppatternthatcontinuesuntilaspecialvalueisinputiscalleda(n)()
答案:sentinelloopAlooppatternthataskstheuserwhethertocontinueoneachiterationiscalleda(n)()
答案:interactiveloopAloopisusedtoskipoverasectionofa
溫馨提示
- 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
- 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
- 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
- 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
- 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
- 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
- 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。
最新文檔
- 2025年皖北煤電集團公司掘進工招聘備考題庫及參考答案詳解
- 2025年貴州鹽業(yè)(集團)有限責(zé)任公司貴陽分公司公開招聘工作人員6人備考題庫及完整答案詳解1套
- 3D打印納米復(fù)合材料植入體的抗菌性能
- 2025年四川工商學(xué)院招聘專任教師崗位5人備考題庫及完整答案詳解一套
- 3D打印急救器械的模塊化組合應(yīng)用策略
- 四川省眉山市仁壽縣2024-2025學(xué)年九年級上學(xué)期12月期末化學(xué)試題(含答案)
- 中國鋁業(yè)集團有限公司2026年度高校畢業(yè)生招聘1289人備考題庫及一套參考答案詳解
- 重癥血液吸附專家指導(dǎo)意見2026
- 2025年共青團中央所屬事業(yè)單位社會人員公開招聘18人備考題庫含答案詳解
- 2025年江陰市東舜城鄉(xiāng)一體化建設(shè)發(fā)展有限公司公開招聘工作人員9人備考題庫及答案詳解一套
- 2025年馬鞍山市住房公積金管理中心編外聘用人員招聘3名考試筆試模擬試題及答案解析
- 2026年山東力明科技職業(yè)學(xué)院單招職業(yè)技能考試題庫含答案詳解
- (一診)德陽市高中2023級高三第一次診斷考試生物試卷(含答案)
- 術(shù)后疲勞綜合征的炎癥反應(yīng)抑制策略
- 慢性阻塞性肺疾病的營養(yǎng)改善方案
- 貴州國企招聘:2025貴陽市衛(wèi)生健康投資有限公司招聘(公共基礎(chǔ)知識)綜合能力測試題附答案
- 2026年跨境電商培訓(xùn)課件
- 2026年安徽水利水電職業(yè)技術(shù)學(xué)院單招職業(yè)適應(yīng)性測試題庫帶答案詳解
- 醫(yī)院治安防范措施課件
- 2025中原農(nóng)業(yè)保險股份有限公司招聘67人參考筆試題庫及答案解析
- 2025年山東政府采購評審專家考試經(jīng)典試題及答案
評論
0/150
提交評論