In this lesson
- It starts with a question. A method checks every pair of items in a list. With 10 items that is about 100 checks. With 20 items?
- The idea you will find. Ask how the work grows, not how long it takes today. — A method that doubles in cost when the data doubles will survive growth. One that quadruples will not, however fast the machine is. Deciding this before writing the code is cheaper than discovering it when the data arrives.
- How you learn it. By doing: building a chart.
- Length. 5 short steps. Progress saves on this phone.
Part of Python: Sorting & Searching
Sorting, searching and counting — and knowing which approach survives a big list.