Here is the code
#include <iostream> #include <vector> using namespace std; int main () { vector<double> v; v.push_back(2.7); v.push_back(5.6); v.push_back(7.9); for(int = 0; i < v.size(); ++i) { cout << "v[" << i << "]==" << v[i] << "\n"; } } When compiling writes
"C: \ Users \ Nikita \ Desktop \ Untitled1.cpp: 15: 41: Waring: missing terminating '" "character [-Winvalid-pp-token]
cout << "v[" << i << "]==" << v[i] << "\n"; ^ "C: \ Users \ Nikita \ Desktop \ Untitled1.cpp: 15: 41: error: expected expression
1error and 1 waring generated
Please explain why this is happening? I am a beginner and still learn.