Im using macOs for the 1st time and now I have a problem with working on c++ in VScode. After start of program I always so this error. Please, help anyone with this. Tnx!
code
#include <iostream>
int main(){
int num1 = 5;
int num2 = 10;
int sum = num1 + num2;
std::cout << sum << std::endl;
return 0;
}
output
Undefined symbols for architecture arm64: "_main", referenced from: <initial-undefines> ld: symbol(s) not found for architecture arm64 clang: error: linker command failed with exit code 1 (use -v to see invocation)
tnx for help!
enter image description here
Стукановский Максим is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.