2019-06-17 14:52:05 +00:00
|
|
|
1.Add comments to explain what you are trying to do.
|
2019-05-28 21:28:20 +00:00
|
|
|
|
2019-06-17 14:52:05 +00:00
|
|
|
2.No "using namespace std;"
|
|
|
|
|
|
|
|
3.Clearly declare "private" inside of class. For example:
|
2019-05-28 21:28:20 +00:00
|
|
|
|
|
|
|
use
|
|
|
|
```c++
|
|
|
|
class item{
|
|
|
|
private:
|
|
|
|
int price;
|
|
|
|
public:
|
|
|
|
getPrice();
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
instead of class
|
|
|
|
|
|
|
|
```c++
|
|
|
|
class item{
|
|
|
|
int price;
|
|
|
|
public:
|
|
|
|
getPrice();
|
|
|
|
}
|
|
|
|
```
|
|
|
|
|
|
|
|
|
2019-06-17 14:52:05 +00:00
|
|
|
4.Declare inheritance type(public, private, protected) when using inheritance.
|
2019-05-28 21:28:20 +00:00
|
|
|
|
2019-06-17 14:52:05 +00:00
|
|
|
5.If not finished with code, add a TODO as comments.
|