0
Typo in slide "Private" in Encapsulation
in the main function, myClass should be MyClass, as it is a datatype declaration.
2 ответов
+ 4
While pascal case is a common style for class declarations, you're free to use any convention you wish; it's not enforced by the C++ standard. Whatever you choose, you should strive to use it consistently throughout the code base. Seeing as they keep it as "myClass" throughout the lesson, I don't believe that this is a typo.
However, they do switch to "MyClass" in the questions, which could be confusing.
0
right. it's defined as MyClass and then used as myClass.