-10

I am new to Visual Studio for C++ (just moved in from Ubuntu g++ / gcc).
I am having trouble since Visual Studio does not seem to recognize
std::vector, std::complex<>, std::complex<double>, etc.
That all worked fine for Linux. How to do incorporate these in Visual Studio?

Just Shadow
  • 10,860
  • 6
  • 57
  • 75
Link L
  • 439
  • 7
  • 25

1 Answers1

0

You probably copy pasted functions but forgot to include appropriate headers (newbie mistake).
Just try this:

#include <iostream>
#include <vector>
#include <complex>

using namespace std;

int main()
{
    cout<<"Hello World";

    return 0;
}
Just Shadow
  • 10,860
  • 6
  • 57
  • 75
  • 1
    Pardon me but what problem is this answer solving? How is including vector different in visual studio than anywhere else? – Aykhan Hagverdili Mar 31 '19 at 09:45
  • I guess the problem was that he just copy-pasted functions but forgot to include appropriate headers. So this answer just hints that he should include the headers as well. – Just Shadow Mar 31 '19 at 10:18