page170.html

来自「Data Structures And Algorithms With Obje」· HTML 代码 · 共 39 行

HTML
39
字号
<HTML><HEAD><TITLE>Array Implementation</TITLE></HEAD><BODY bgcolor="#FFFFFF"> <a href="../index.html" target="_top"><img src="../icons/usins.gif" alt="Logo" align=right></a><b>Data Structures and Algorithms with Object-Oriented Design Patterns in Python</b><br><A NAME="tex2html3161" HREF="page171.html"><IMG WIDTH=37 HEIGHT=24 ALIGN=BOTTOM ALT="next" SRC="../icons/next_motif.gif"></A> <A NAME="tex2html3159" HREF="page169.html"><IMG WIDTH=26 HEIGHT=24 ALIGN=BOTTOM ALT="up" SRC="../icons/up_motif.gif"></A> <A NAME="tex2html3153" HREF="page169.html"><IMG WIDTH=63 HEIGHT=24 ALIGN=BOTTOM ALT="previous" SRC="../icons/previous_motif.gif"></A>  <A NAME="tex2html3163" HREF="page611.html"><IMG WIDTH=43 HEIGHT=24 ALIGN=BOTTOM ALT="index" SRC="../icons/index_motif.gif"></A> <BR><HR><H2><A NAME="SECTION007110000000000000000">Array Implementation</A></H2><A NAME="seclistslista">&#160;</A><P>This section presents an array-based implementation of ordered lists.Program&nbsp;<A HREF="page170.html#progorderedListAsArraya"><IMG  ALIGN=BOTTOM ALT="gif" SRC="../icons/cross_ref_motif.gif"></A> introduces the <tt>OrderedListAsArray</tt> class.The <tt>OrderedListAsArray</tt> class extendsthe abstract <tt>OrderedList</tt> classdefined in Program&nbsp;<A HREF="page169.html#progorderedLista"><IMG  ALIGN=BOTTOM ALT="gif" SRC="../icons/cross_ref_motif.gif"></A>.<P><P><A NAME="8851">&#160;</A><A NAME="progorderedListAsArraya">&#160;</A> <IMG WIDTH=575 HEIGHT=142 ALIGN=BOTTOM ALT="program8634" SRC="img734.gif"  ><BR><STRONG>Program:</STRONG> <tt>OrderedListAsArray</tt> class <tt>__init__</tt> method.<BR><P><BR> <HR><UL> <LI> <A NAME="tex2html3164" HREF="page171.html#SECTION007111000000000000000">Instance Attributes</A><LI> <A NAME="tex2html3165" HREF="page172.html#SECTION007112000000000000000">Creating a List and Inserting Items</A><LI> <A NAME="tex2html3166" HREF="page173.html#SECTION007113000000000000000">Finding Items in a List</A><LI> <A NAME="tex2html3167" HREF="page174.html#SECTION007114000000000000000">Removing Items from a List</A><LI> <A NAME="tex2html3168" HREF="page175.html#SECTION007115000000000000000">Positions of Items in a List</A><LI> <A NAME="tex2html3169" HREF="page176.html#SECTION007116000000000000000">Finding the Position of an Item and Accessing by Position</A><LI> <A NAME="tex2html3170" HREF="page177.html#SECTION007117000000000000000">Inserting an Item at an Arbitrary Position</A><LI> <A NAME="tex2html3171" HREF="page178.html#SECTION007118000000000000000">Removing Arbitrary Items by Position</A></UL><HR><A NAME="tex2html3161" HREF="page171.html"><IMG WIDTH=37 HEIGHT=24 ALIGN=BOTTOM ALT="next" SRC="../icons/next_motif.gif"></A> <A NAME="tex2html3159" HREF="page169.html"><IMG WIDTH=26 HEIGHT=24 ALIGN=BOTTOM ALT="up" SRC="../icons/up_motif.gif"></A> <A NAME="tex2html3153" HREF="page169.html"><IMG WIDTH=63 HEIGHT=24 ALIGN=BOTTOM ALT="previous" SRC="../icons/previous_motif.gif"></A>  <A NAME="tex2html3163" HREF="page611.html"><IMG WIDTH=43 HEIGHT=24 ALIGN=BOTTOM ALT="index" SRC="../icons/index_motif.gif"></A> <P><ADDRESS><img src="../icons/bruno.gif" alt="Bruno" align=right><a href="../copyright.html">Copyright &#169; 2003</a> by <a href="../signature.html">Bruno R. Preiss, P.Eng.</a>  All rights reserved.</ADDRESS></BODY></HTML>

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?