I recently replaced my hard drives and install win 10 pro. Now, I cannot even run the most simple C++ program on VS code.
For example, run
1 2 3 4 5 6 7 8
|
#include <iostream>
int main()
{
std::cout << "something" << "\n" ;
}
|
I get
Windows PowerShell
Copyright (C) Microsoft Corporation. All rights reserved.
Try the new cross-platform PowerShell
https://aka.ms/pscore6
PS D:\Programming\ML\DSFS\visualization> g++ test.cpp
test.cpp: In function 'int main()':
test.cpp:5:10: error: 'cout' is not a member of 'std'
std::cout << "something" << "\n" ;
^~~~
test.cpp:5:10: note: 'std::cout' is defined in header '<iostream>'; did you forget to '#include <iostream>'?
test.cpp:2:1:
+#include <iostream>
test.cpp:5:10:
std::cout << "something" << "\n" ;
^~~~
Please help, thanks in advance.