MCPcopy Create free account
hub / github.com/ShiqiYu/CPP / setBorn

Method setBorn

week09/examples/firstclass.cpp:21–27  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19 name[len] = '\0';
20 }
21 void setBorn(int b)
22 {
23 if (b >= 1990 && b <= 2020 )
24 born = b;
25 else
26 std::cerr << "The input b is " << b << ", and should be in [1990, 2020]." << std::endl;
27 }
28 void setGender(bool isMale)
29 {
30 male = isMale;

Callers 1

mainFunction · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected