Scusate la domanda forse ingenua, ma ho provato a compilare un programma scritto da terzi giusto per vedere come andava, ma il mio Visual C++ non me lo compila nemmeno, restituendomi una stack di errori infinita. Le prime righe della stack sono:
Credo ci sia un problema con gli header/librerie, ma non so bene quale possa essere.Codice PHP:1>newton.cpp(55): warning C4018: '<' : signed/unsigned mismatch
1>newton.cpp(71): warning C4018: '<' : signed/unsigned mismatch
1>newton.cpp(95): warning C4018: '>=' : signed/unsigned mismatch
1>newton.cpp(104): warning C4018: '>=' : signed/unsigned mismatch
1>newton.cpp(135): warning C4018: '<' : signed/unsigned mismatch
1>newton.cpp(185): error C2679: binary '<<' : no operator found which takes a right-hand operand of type 'std::string' (or there is no acceptable conversion)
Il programma include le seguenti librerie:
Devo fisicamente includere qualche file nel progetto? Al momento io ho la seguente configurazione:Codice PHP:#include <iostream>
#include <vector>
#include <cmath>
using namespace std;
![]()
Usando le librerie scritta da Stroustrup ed allegate ai suoi testi (std_lib_facilities.h) le importavo direttamente e fisicamente in "Header files", ma usando il namespace std non dovrebbe essere tutto riconosciuto automaticamente?
Grazie!

Rispondi quotando