COMP 302 Lecture Notes - Lecture 25: Type Constructor, Subtyping, Code Reuse

22 views7 pages

Document Summary

March 21, 2017 ( lecture 25 // week 11, lecture 1 ) Today we are talking about a fundamental concept called subtyping . A is a subset of b: a b means that a and b are collections, and this notation means that everything that is in a, is also in b. B might be a larger collectio or the same size. It includes everything in a. this is not what we are talking about today!!! When you think about collections, they come with: (1) set of elements (2) set of operations you can perform on them. This is why the set view is not adequate. We need to focus on what we can do with the things in the computational collection (aka 2). For example, you might have two similar collections in terms of elements, but with different operations.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents

Related Questions