I'm just starting out with programming and want to know the best way to set up C/C++ compilers on Windows. I've looked for answers in various places but keep getting mixed opinions. Some folks say MSVC is the way to go, while others claim WSL is faster than MSYS2. What's the best choice for someone like me?
6 Answers
Think about what you'll be doing. If you’re focused on creating Windows apps, Visual Studio is probably your best bet—it’s popular among both beginners and pros due to its robust features. However, if you want to explore scientific programming or need something closer to a Linux environment, you might find WSL2 more suitable as it offers greater flexibility with tools like gcc or clang.
There's really no single answer here. For beginners diving into C++, I'd recommend checking out MinGW. It's a Windows-friendly compiler that’s not only lightweight, making it easy to download and install, but it's also based on the GNU C++ compiler, so it generally stays updated with the latest C++ standards. You can find a simple guide on how to set it up easily online.
There isn't a 'best' option; it really depends on your goals. MSVC excels if you're developing Windows applications, while WSL gives a Linux-like experience that's great for learning. MSYS2 is useful but less recommended these days. For many beginners, starting with WSL is advantageous since it enables compatibility with a wide range of tutorials and development resources. You can always add MSVC later if Windows-specific needs arise.
It all boils down to what you're looking for. If convenience is key, consider using an IDE that includes compilers, like CLion. It'll save you a lot of hassle setting things up yourself!
Just keep in mind that WSL and MSYS2 serve different purposes. WSL acts like a full Linux environment, which is great if you want to build Linux applications, while MSYS2 provides a more limited Linux-like experience for Windows. If you aim for cross-platform work later, WSL might be more beneficial.
If you’re just starting out, I’d suggest going with Visual Studio. It’s a complete package that provides an easy-to-use debugger and a lot of features that will help you as you learn. It’s pretty hefty on the download side, but all the tools you need are right there in one place.

Related Questions
How To: Running Codex CLI on Windows with Azure OpenAI
Set Wordpress Featured Image Using Javascript
How To Fix PHP Random Being The Same
Why no WebP Support with Wordpress
Replace Wordpress Cron With Linux Cron
Customize Yoast Canonical URL Programmatically