Full lesson | Create for a teacher a set of content for giving a lesson, beginning with the lesson plan. Each new block of materials must begin with an H1 heading (other subheaders must be H2, H3, etc). When you describe required pictures, write those descriptions in curly brackets, for example: {A picture of a triangle} |
Which subject | Computer science |
What topic | Programming if lists |
What length (min) | 30 |
What age group | Year or Grade 10 |
Class size | 20 |
What curriculum | |
Include full script | |
Check previous homework | |
Ask some students to presents their homework | |
Add a physical break | |
Add group activities | |
Include homework | |
Show correct answers | |
Prepare slide templates | |
Number of slides | 5 |
Create fill-in cards for students | |
Create creative backup tasks for unexpected moments |
Programming with Lists
Year 10 (Ages 14-15)
Computer Science
20 Students
This lesson follows the UK Computer Science curriculum, focusing on the programming fundamentals, particularly on data structures like lists.
Step Number | Step Title | Length (minutes) | Details |
---|---|---|---|
1 | Introduction to Lists | 5 | Introduce the concept of lists, discussing their importance in programming with real-world examples. |
2 | Demonstration | 10 | Show how to create and manipulate lists using a programming language. Utilize the projector for visual aid. |
3 | Printable card distribution | 5 | Hand out printable cards to each student for a corresponding activity. Explain how they will be used during the lesson. |
4 | Practical Activity | 5 | Students will fill out the printable cards based on the programming tasks discussed. |
5 | Random Check/Collection | 3 | Collect cards or conduct a random check of the filled cards to assess understanding and engagement. |
6 | Assign Homework | 2 | Assign homework that reinforces the concepts learned in class. Provide clear instructions without seeking presentations. |
Summarize key points from the lesson and encourage students to revise the concepts of lists in programming for their homework. Provide information on how to seek assistance if needed before the next lesson.
"Good morning everyone! Today, we are going to dive into the fascinating world of programming with lists. Can anyone tell me what they think a list is in programming?
[Pause for responses]
"Great thoughts! Lists are an essential data structure used in many programming languages to organize and store collections of data. For example, think about a shopping list or a list of your favorite movies. In programming, lists can help us manage groups of related data efficiently. By the end of this lesson, you will be able to create and manipulate lists in your programs. Let’s get started!"
"Now, let’s look at how we can create a list in a programming language. I will use Python for this demonstration. Please direct your attention to the screen.
[Project demonstration]
"Here, I have a simple list of fruits: fruits = ['apple', 'banana', 'cherry']
.
"Now, I can add an item to this list using the append()
method. Watch how I do this:
fruits.append('orange')
print(fruits)
"Next, I can access specific items in the list by their index. In Python, the index starts at 0. For example, fruits[0]
will give us 'apple'.
"Hands-on time is coming up, but first, let’s ensure everyone is clear on this."
"Now, I’m going to hand out some printable cards to each of you. These cards represent different tasks that relate to manipulating lists. Once you receive your card, please take a moment to read the task and think about what you need to do.
[Distribute cards]
"Remember that these cards will help guide you through our practical activity."
"Now that you have your cards, let’s get into our practical activity! You will need to fill out your cards based on the programming tasks discussed. This could involve creating new lists, adding items, or accessing specific elements.
"You have 5 minutes for this activity. Stick to the task on the card, and I will be walking around to assist anyone who has questions."
[Monitor the activity and assist as needed]
"Okay, time is up! I would like to collect your cards now to see how you all did with the tasks.
“Please make sure your name is on the card. I will do a brief random check, so I may pick a few of you to share how you approached your tasks and what you learned.”
[Collect and review cards]
"Excellent work today, everyone! As a follow-up to this lesson, I would like you to complete the homework I’ll assign now.
"Your task is to write a short program that creates a list with at least five items, adds an additional item, and prints the final list. Please document what you did and the output you received.
"You will submit this on our next class day, and remember, if you have any questions or need assistance, feel free to reach out to me or consult the resources provided."
"To wrap things up, we learned about lists and how they can store multiple data items efficiently. Remember, lists are powerful tools in programming, helping us organize data.
"Make sure to revise these concepts for your homework. If you feel unsure about any topics we covered, please don’t hesitate to seek help before our next lesson. Thank you for your attention today, and I look forward to seeing your homework!"
Define what a list is in programming. Provide an example of a list in your explanation.
Create a list in Python that includes at least five different fruits. Write out the code you used to create the list.
Using the list you created in question 2, use the append()
method to add another fruit of your choice to the list. Show the code that accomplishes this.
Write code to access and print the first and last items from your list. What are the outputs of these print statements?
Explain what an index is in the context of lists. Why does Python start counting from zero?
Create a list of your three favourite books. Include your reasoning for why you chose these books in a few sentences.
Compare and contrast a list with another data structure, such as a tuple or dictionary. What are the key differences between them?
Document the steps you took to complete your homework, including any challenges you faced and how you overcame them.
Reflect on the importance of lists in programming. Why do you think they are used frequently?
Review your classmates' work (if applicable) and provide one piece of constructive feedback on their list manipulation tasks. What did you learn from their approach?
Question | Answer |
---|---|
What is a list in programming? | |
Can you provide an example of a real-world list that relates to programming? | |
How do you create a list in Python? | |
What method do you use to add an item to a list in Python? | |
What is the index of the first item in a Python list? | |
How do you access the second item in a list called fruits ? |
|
What should you include on your card during the practical activity? | |
How long do you have for the practical activity? | |
What program will you write for your homework assignment? | |
Why are lists considered powerful tools in programming? |