List[Null, Null, Null, Null, Null, Null, Null, Notebook[List[Cell[CellGroupData[List[Cell["Exercise 3", "Title"], Cell[CellGroupData[List[Cell["Using Inheritance and Access Control", "Section"], Cell[TextData[List["Write a class, ", StyleBox["Person", Rule[FontFamily, "Courier"]], ", with the variables ", StyleBox["name", Rule[FontFamily, "Courier"]], ", ", StyleBox["weight", Rule[FontFamily, "Courier"]], " and ", StyleBox["ID", Rule[FontFamily, "Courier"]], ", where ", StyleBox["ID", Rule[FontFamily, "Courier"]], " should be protected. The next class ", StyleBox["Employed", Rule[FontFamily, "Courier"]], " should inherit from ", StyleBox["Person", Rule[FontFamily, "Courier"]], " and have a protected variable, salary. The last class, ", StyleBox["Programmer", Rule[FontFamily, "Courier"]], ",  contains the variables ", StyleBox["favProgLang", Rule[FontFamily, "Courier"]], " (favorite programming language) and ", StyleBox["drinksJoltCola", Rule[FontFamily, "Courier"]], ". "]], "Text"], Cell[CellGroupData[List[Cell["Answer", "Subsection"], Cell["", "Text"], Cell["class Person\n  String name;\n  Real weight;\nprotected\n  Integer ID;\nend Person;", "ModelicaInput"], Cell["", "Text"], Cell["class Employed\n  extends Person;\nprotected\n  Real salary;\nend Employed;", "ModelicaInput"], Cell["", "Text"], Cell["class Programmer\n  extends Employed;\n  String favProgLang;\n  Boolean drinksJoltCola;\nend Programmer;", "ModelicaInput"]], Closed]]], Open]], Cell[CellGroupData[List[Cell["Question", "Section"], Cell[TextData[List["Which protected variable(s) does the class ", StyleBox["Employed", Rule[FontFamily, "Courier"]], " have?"]], "Text"], Cell[CellGroupData[List[Cell["Answer", "Subsection"], Cell[TextData[List[StyleBox["salary", Rule[FontFamily, "Courier"]], " and ", StyleBox["ID", Rule[FontFamily, "Courier"]]]], "Text"]], Closed]]], Open]], Cell[CellGroupData[List[Cell["A Different Exercise", "Section"], Cell[TextData[List["Use the same class ", StyleBox["Person", Rule[FontFamily, "Courier"]], ", but use this changed class ", StyleBox["Employed", Rule[FontFamily, "Courier"]], " below:"]], "Text"], Cell["class Employed\nprotected\n  extends Person;\nprotected\n  Real salary;\nend Employed;", "ModelicaInput"], Cell[TextData[List["\nNow which protected variable(s) does the class ", StyleBox["Employed", Rule[FontFamily, "Courier"]], " have?"]], "Text"], Cell[CellGroupData[List[Cell["Answer", "Subsection"], Cell[TextData[List[StyleBox["name", Rule[FontFamily, "Courier"]], ",  ", StyleBox["weight, ", Rule[FontFamily, "Courier"]], StyleBox["salary", Rule[FontFamily, "Courier"]], " and ", StyleBox["ID", Rule[FontFamily, "Courier"]]]], "Text"]], Closed]]], Open]]], Open]]], Rule[FrontEndVersion, "4.1 for Microsoft Windows"], Rule[ScreenRectangle, List[List[0, 1280], List[0, 951]]], Rule[WindowSize, List[758, 972]], Rule[WindowMargins, List[List[55, Automatic], List[Automatic, 0]]], Rule[StyleDefinitions, "MathModelica.nb"]], Null, Null, Null, Null, Null]