So basically im 14 and just startd c++, i bought a book and am self learning, im doing quite well but i am having trouble with my newest code. Please fix it, and tell me what i can do next time to fix it myself. Thank you.
Code:
#include <iostream>
using namespace std ;
int main ()
{
const double PI = 3.145926536 ;
cout << "6\" circle circumference: " << (PI * 6) << endl ;
enum ;
{ RED=1, YELLOW, GREEN, BROWN, BLUE, PINK, BLACK } ;
cout << "I shot a red worth:" << endl ;
cout << "Then shot a blue worth:" << endl ;
cout << "Total scored: " << ( RED + BLUE ) << endl ;
typedef enum { NEGATIVE , POSITIVE } charge ;
charge neutral = NEGATIVE , live = POSITIVE ;
cout << "Neutral wire:" << neutral << endl ;
cout << "Live wire:" << live << endl ;
Return 0 ;
}
It would also help if you explained what the outcome is meant to be. Is this meant to be a program about archery or something because I have absolutely no idea. It would also be helpful to wrap your code in the code tags, like:
1 2 3 4 5 6
int useCodeTags()
{
cout << "They make things a lot easier to read!" << endl;
return 0;
}