Join Barron Stone for an in-depth discussion in this video Mutable and immutable data, part of Programming Foundations: Real-World Examples.
- As you learn about programming, you might encounter…two funny sounding words: mutable and immutable,…which are just fancy words to describe whether or not…something can be changed.…A mutable object can be modified after it's been created,…whereas an immutable object cannot.…Once you've created an immutable object,…you're stuck with it.…Object types will either be mutable or immutable,…and it's a good idea to learn which is which…in your programming language, so you can be sure…to select the right type of object for different jobs.…For example, you'd want to avoid using immutable…data types to store values in your program…that we're going to constantly be changing…or needing to be changed.…
One example of a mutable object in Python…is the list, which is an object type that acts…as a container to store an ordered collection…of other objects.…You can think of this rack of clothes as a list,…which contains several different clothing objects.…As Olivia sorts through the rack of clothes…to pick an outfit for today,…
- Reusing functions
- Local vs. global variables
- Creating and naming custom objects
- Class inheritance
- Modules and packages
- Multidimensional lists and tuples
- Queues and stacks
- Creating and combining sets
- Storing data in dictionaries
- If/else and switch statements
- For vs. while loops
- Error handling
- Polling and event-driven programming
Skill Level Beginner
3. Class Inheritance
4. Modules and Packages
5. Lists and Tuples
6. Queues and Stacks
9. Conditional Execution
11. Error Handling
12. Polling and Event-Driven Programming
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.