Nevermind! I forgot to using std::setw;
.
setw not found in MSVC 2013 or NetBeans
-
28-06-2022 - |
Question
I'm trying to write some simple code to learn cout formatting, and both the IDEs listed in the title complain that they can't find/resolve the identifier setw(). Here is my code:
#include <cstdlib>
#include <iostream>
#include <iomanip>
using std::cout;
using std::cin;
using std::endl;
using std::vector;
using std::string;
int main() {
cout << setw(10) << "Hello";
return 0;
}
Solution
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow