Essay - Published: 2016.03.21 |
DISCLOSURE: If you buy through affiliate links, I may earn a small commission. (disclosures)
**Problem: **I’ve made a C++ project in Visual Studio 2015, but can’t see the std::cout console logs I’ve created.
Solution:
First, make sure you’re looking in the correct place. When you run your program, you should see a** black console window** appear. Your output will be inside of that.
If you don’t see a black console window, continue to the last bit.
Sometimes console logs aren’t pushed unless you flush the stream. You can do this by appending << endl; to the end of each of your logs.
If you don’t have a console app, VS may not know what to do with your std::couts. You can ensure this by going to Project > Properties > Linker > System > Subsystem and choosing “Console”
The best way to support my work is to like / comment / share for the algorithm and subscribe for future updates.