Page 23 - Python Cơ Bản
P. 23

8VSRK RLMАY XVšЬRK LвT FϰR QYРR XVY] \YϴX QШX TL϶R Xм

          FϴX OΧ  HрE ZɧS MRHI\  GжE QϲRK XLɳ RЎY XVY] \YϴX чЎR QШX


          TL϶R Xм OLɺRK XТR XϰM XLɳ иRK HдRK WЌ FɨS PЦM  (S чɹ  XVšЪG


          OLM XVY] \YϴX QШX TL϶R Xм  FϰR G϶R OMВQ XVE \IQ TL϶R Xм

          Rɧ] чɪ XТR XϰM LE] GLšE  ,MЖR XϰM T]XLSR OLɺRK LЦ XVв LɧQ


          RɧS чВ OMВQ XVE Wр XТR XϰM GжE QШX TL϶R Xм XVSRK QϲRK




          'ɹ   GɨGL XLšЬRK XLϴ] чВ OMВQ XVE чɹ Pɧ Ű0SSO FIJSVI ]SY


          PIETű  0&=0  Zɧ Ű)EWMIV XS EWO JSVKMZIRIWW XLER


          TIVQMWWMSRű  )%*4




          :ɴ Hд ZА Ű0SSO FIJSVI ]SY PIET  0&=0 ű






           if index < len(array):

               array[index]

           else:
               # handle this






          :ɴ Hд ZА Ű)EWMIV XS EWO JSVKMZIRIWW XLER TIVQMWWMSRű


           )%*4
   18   19   20   21   22   23   24   25   26   27   28