#include <iostream>
#include <cstdio>
#include <iostream>
usingnamespace std;
class kevin;
{
Public :
int strength;
int speed;
void talk()
{cout << "I am talking" << endl;
};
};
int main()
{
kevin.k
k.speed = 50;
k.strength = 50;
cout << "My strength is: " << speed << " And my speed is: " << speed;
k.talk();
return 0;
}
I keep receiving the following error while trying to debug on line 11
#include <iostream>
#include <cstdio>
#include <iostream>
usingnamespace std;
class kevin //no semicolon ; here
{
public: //lowercase p here
int strength;
int speed;
void talk() {
cout << "I am talking" << endl;
} //no semicolon ; here
};
int main()
{
kevin k; //no dot . here
k.speed = 50;
k.strength = 50;
// cout << "My strength is: " << speed << " And my speed is: " << speed;
cout << "My strength is: " << k.strength << " And my speed is: " << k.speed;
//you might consider printing a line break here, i.e. '\n' or endl
k.talk();
return 0;
}