Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Learn Clearing the inventory | Lists
Python Ninja

Swipe to show menu

book
Clearing the inventory

The ninja's inventory is not endless, it is currently full, so he can't take any more animals with him. However, you can free up space in the inventory using the inventory.clear() method.

Task

Swipe to start coding

Solution

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

SectionΒ 7. ChapterΒ 6
py

ninja.py

We're sorry to hear that something went wrong. What happened?

Ask AI

expand
ChatGPT

Ask anything or try one of the suggested questions to begin our chat

book
Clearing the inventory

The ninja's inventory is not endless, it is currently full, so he can't take any more animals with him. However, you can free up space in the inventory using the inventory.clear() method.

Task

Swipe to start coding

Solution

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

SectionΒ 7. ChapterΒ 6
Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
We're sorry to hear that something went wrong. What happened?
some-alt