Join 36000+ teachers and students using TTIO.
Searching an ordered list of data is easier or more efficient than searching an unordered list. It is worth looking into the B-Tree (B stands for 'balanced' not 'binary'!) A database index is a data structure that improves the speed of data retrieval operations on a database table at the cost of additional writes and storage space to maintain the index data structure.
Indexes are used to quickly locate data without having to search every row in a database table every time a database table is accessed. Indexes can be created using one or more columns of a database table, providing the basis for both rapid random lookups and efficient access of ordered records. There are advantages and disadvantages to using an index.
www.teachyourselfpython.com