31
For the most part, all that’s needed is a pair of calls to strcpy to copy
the two arguments (new_green and new_red) to the two member
variables (green_string and red_string). By the way, how many of you
have seen this use of strcpy before? If you haven’t seen it, don’t worry–
Thinking Cap Implementation
void ThinkingCap::slots(char new_green[ ], char new_red[ ])
{
assert(strlen(new_green) < 50);
For the most part, the function’s body is no different
than any other function body.