The bakery can fit at most 12 characters on a cake (spaces count too). Write fits_on_cake(msg): true if it fits, false if not. An empty message fits.
fits_on_cake("Happy Birthday")→Falsefits_on_cake("Hi Mom")→Truebool fits_on_cake(const string &msg)#include <string>
using namespace std;
bool fits_on_cake(const string &msg) {
int length = 0;
// your code here: set length to how many characters msg has
return length <= 12;
}
Run tries the examples. When they look right, Submit.