🎓 EASYTUTORGUIDE · Complete Python Course

Very beginner → professional Python · 60 chapters · 900 topics

EasyTutorGuide

Chapter 13: Lists

Complete Python lesson for very beginners. Technical words are explained in simple language, and every outline topic includes a practical example, expected output, steps, and practice.

Python CourseVery Beginner Friendly15 TopicsExamples + Output20 Q&A
Chapter 13 · 15 topics
100%

Chapter Overview

This Python tutorial chapter covers Lists through 15 connected topics. Work through the examples in order, check the expected output, and complete the practice after each topic.

  • 13.1 Creating Lists
  • 13.2 Accessing Elements
  • 13.3 Negative Indexing
  • 13.4 Slicing
  • 13.5 Updating Elements
  • Plus 10 additional Python topics in this chapter.

13.1 Creating Lists

Creating Lists is part of Lists. In simple language, it means an ordered, changeable collection.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Creating Lists (an ordered, changeable collection).

Python / Practical Example

items = [10, 20, 30]
print(items)

Expected Output

[10, 20, 30]

Step-by-Step Explanation

  1. Use square brackets.
  2. Separate items with commas.
  3. A list keeps item order and can be changed.
Practice: Re-type the example for “Creating Lists”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.2 Accessing Elements

Accessing Elements is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Accessing Elements (a Python idea used while learning lists).

Python / Practical Example

items = [1,2,3]
print(items[-1])

Expected Output

3

Step-by-Step Explanation

  1. Read the example from top to bottom.
  2. Identify the value, object, or operation related to this topic.
  3. Change one small input and predict the result before running it.
Practice: Re-type the example for “Accessing Elements”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.3 Negative Indexing

Negative Indexing is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Negative Indexing (a Python idea used while learning lists).

Python / Practical Example

items = [10, 20, 30]
print(items[-1])

Expected Output

30

Step-by-Step Explanation

  1. Negative indexes count from the end.
  2. -1 means the last item.
  3. The original collection is unchanged.
Practice: Re-type the example for “Negative Indexing”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.4 Slicing

Slicing is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Slicing (a Python idea used while learning lists).

Python / Practical Example

value = "Python"
print(value[1:4])

Expected Output

yth

Step-by-Step Explanation

  1. Slice syntax uses start:stop.
  2. The start index is included.
  3. The stop index is excluded.
Practice: Re-type the example for “Slicing”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.5 Updating Elements

Updating Elements is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Updating Elements (a Python idea used while learning lists).

Python / Practical Example

items = [1,2,3]
print(items[-1])

Expected Output

3

Step-by-Step Explanation

  1. Read the example from top to bottom.
  2. Identify the value, object, or operation related to this topic.
  3. Change one small input and predict the result before running it.
Practice: Re-type the example for “Updating Elements”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.6 append()

append() is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: append() (a Python idea used while learning lists).

Python / Practical Example

items = ["a", "b"]
items.append("c")
print(items)

Expected Output

['a', 'b', 'c']

Step-by-Step Explanation

  1. Create a list.
  2. append() adds one item to the end.
  3. Print the changed list.
Practice: Re-type the example for “append()”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.7 extend()

extend() is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: extend() (a Python idea used while learning lists).

Python / Practical Example

items = [1, 2]
items.extend([3, 4])
print(items)

Expected Output

[1, 2, 3, 4]

Step-by-Step Explanation

  1. Create a list.
  2. extend() adds each item from another iterable.
  3. Print the resulting list.
Practice: Re-type the example for “extend()”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.8 insert()

insert() is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: insert() (a Python idea used while learning lists).

Python / Practical Example

items = ["a", "c"]
items.insert(1, "b")
print(items)

Expected Output

['a', 'b', 'c']

Step-by-Step Explanation

  1. Choose the insertion index.
  2. insert() places the item there.
  3. Existing items move to the right.
Practice: Re-type the example for “insert()”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.9 Removing Elements

Removing Elements is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Removing Elements (a Python idea used while learning lists).

Python / Practical Example

items = ["a", "b", "c"]
items.remove("b")
print(items)

Expected Output

['a', 'c']

Step-by-Step Explanation

  1. remove() deletes the first equal value.
  2. The list changes in place.
  3. Use pop() when you need removal by index.
Practice: Re-type the example for “Removing Elements”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.10 Sorting

Sorting is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Sorting (a Python idea used while learning lists).

Python / Practical Example

values = [3, 1, 2]
print(sorted(values))
print(values)

Expected Output

[1, 2, 3]
[3, 1, 2]

Step-by-Step Explanation

  1. sorted() returns a new sorted list.
  2. The original list remains unchanged.
  3. list.sort() would sort the list in place.
Practice: Re-type the example for “Sorting”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.11 Reversing

Reversing is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Reversing (a Python idea used while learning lists).

Python / Practical Example

values = [1, 2, 3]
values.reverse()
print(values)

Expected Output

[3, 2, 1]

Step-by-Step Explanation

  1. reverse() changes a list in place.
  2. The order is reversed.
  3. No new list is required for this operation.
Practice: Re-type the example for “Reversing”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.12 Searching

Searching is part of Lists. In simple language, it means a Python idea used while learning lists.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Searching (a Python idea used while learning lists).

Python / Practical Example

items = [1,2,3]
print(items[-1])

Expected Output

3

Step-by-Step Explanation

  1. Read the example from top to bottom.
  2. Identify the value, object, or operation related to this topic.
  3. Change one small input and predict the result before running it.
Practice: Re-type the example for “Searching”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.13 Copying Lists

Copying Lists is part of Lists. In simple language, it means an ordered, changeable collection.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Copying Lists (an ordered, changeable collection).

Python / Practical Example

original = [[1], [2]]
shallow = original.copy()
shallow[0].append(9)
print(original)

Expected Output

[[1, 9], [2]]

Step-by-Step Explanation

  1. copy() makes a shallow copy of the outer container.
  2. Nested mutable objects can still be shared.
  3. Use deepcopy() only when a fully independent nested copy is actually needed.
Practice: Re-type the example for “Copying Lists”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.14 Nested Lists

Nested Lists is part of Lists. In simple language, it means an ordered, changeable collection.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: Nested Lists (an ordered, changeable collection).

Python / Practical Example

items = [1,2,3]
print(items[-1])

Expected Output

3

Step-by-Step Explanation

  1. Read the example from top to bottom.
  2. Identify the value, object, or operation related to this topic.
  3. Change one small input and predict the result before running it.
Practice: Re-type the example for “Nested Lists”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

13.15 List Best Practices

List Best Practices is part of Lists. In simple language, it means an ordered, changeable collection.

It is one building block of lists and helps you write clearer, more predictable Python programs. For a very beginner, focus first on what goes in, what Python does, and what comes out; details become easier after you run a small example.

Technical words in simple language: List Best Practices (an ordered, changeable collection).

Python / Practical Example

items = [1,2,3]
print(items[-1])

Expected Output

3

Step-by-Step Explanation

  1. Read the example from top to bottom.
  2. Identify the value, object, or operation related to this topic.
  3. Change one small input and predict the result before running it.
Practice: Re-type the example for “List Best Practices”, change one safe input, predict the result before running it, and explain in one sentence why the result changed.

Common Beginner Mistakes

  • Copying code without predicting what each line does.
  • Ignoring the first useful error message or traceback location.
  • Mixing tabs/spaces or changing indentation accidentally.
  • Using data of the wrong type for an operation.
  • Trying to learn many advanced variations before mastering one small working example.

Chapter Practice

  1. Choose three topics from this chapter and re-type their examples without copying and pasting.
  2. For each example, change one input and predict the output first.
  3. Explain five technical terms from this chapter in your own beginner-friendly words.
  4. Create one small program that combines at least two chapter topics.
  5. Keep notes about errors you made and what fixed them.

Mini Project / Challenge

Create a small Python exercise that combines at least three ideas from Lists. Start with a tiny working version, test it, then improve it one step at a time.

  1. Choose three topics from this chapter.
  2. Write or adapt a small Python example using those topics.
  3. Predict the output before running the code.
  4. Test at least one different input.
  5. Write two sentences explaining what the program does and what you learned.

20 Questions & Answers

1. What is the main goal of Chapter 13?

The goal is to understand lists through small explanations, examples, and practice.

2. Should I memorize every command or method?

No. Understand the pattern, practice the common form, and learn how to read documentation when you need exact details.

3. Why are the examples small?

Small examples isolate one idea at a time, which makes errors easier to understand and fix.

4. What should I do when an example gives an error?

Read the last part of the traceback, check spelling and indentation, confirm the required package or file exists, and compare the input types with what the operation expects.

5. Why should I predict output before running code?

Prediction forces you to reason about the program instead of only copying it.

6. What should I remember about Creating Lists?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

7. What should I remember about Accessing Elements?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

8. What should I remember about Negative Indexing?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

9. What should I remember about Slicing?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

10. What should I remember about Updating Elements?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

11. What should I remember about append()?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

12. What should I remember about extend()?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

13. What should I remember about insert()?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

14. What should I remember about Removing Elements?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

15. What should I remember about Sorting?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

16. What should I remember about Reversing?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

17. What should I remember about Searching?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

18. What should I remember about Copying Lists?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

19. What should I remember about Nested Lists?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.

20. What should I remember about List Best Practices?

Remember its beginner meaning, the problem it helps solve, the shape of a small example, and one common situation where it is appropriate.