+ 2
(C++) error: expected primary-expression before '<<' token
I get it on the line cout << ("and a mass of ") << mass << ("x10^") << power << (". "); but on the Android app the ^ doesn't line up so I don't know what it refers to, but I think it was the << after 'of ")' how can I fix these?
5 Antworten
+ 4
Hi Dev. I only just saw your response but I've fixed it now. Misplaced ; :)
+ 3
Try this one
std::cout << "and a mass of " << mass << "x10^" << power << ". ";
or add
using namespace std; before main()
+ 2
Please write by removing parenthesis, it will work
cout << "and a mass of " << mass << "x10^" << power << ". ";
+ 2
same error, just without parentheses.
+ 2
Can I see your code?