 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
 |
| • |
Let’s
quickly build a partial class using operator
|
|
|
overloading
to demonstrate the rules and guidelines
|
|
|
discussed
|
|
|
| • |
We
will re-examine this example again next lecture when
|
|
discussing
user defined type conversions
|
|
|
| • |
The
operations that make sense include:
|
|
|
|
= for
straight assignment of one list to another
|
|
|
|
>>
and << for insertion and extraction
|
|
|
|
+
and += for concatenation of two lists & strings
|
|
|
|
!=,
== for comparison of lists
|
|
|
|
[]
for accessing a particular string in a list
|
|
|
|
++
for iterating to the next string
|
|