I was working on some example that will show C++17 features and stream sockets handling. I was trying to do it in functional style. This is the result:
https://github.com/pantadeusz/hello-cpp-network-sockets
There is README that shows how to compile it.
C++ looks like it is getting better. I haven't used it in over 15 years - except for projects with embedded devices (like ESP8266).
Today, I prefer C# (.NET Core) which is cross platform, open source, and much simpler. See an equivalent project here https://www.c-sharpcorner.com/article/socket-programming-in-C-Sharp/
C# have native network support, and C++ does not.
There are ongoing discussions if the network interface is something that should be present.
The code I provided wraps socket API from operating system (should work on Windows, but I tested it only on Linux).
The thing I like in C++ is that it adapts almost every programming paradigm and extends it a little bit. For example lambdas: in every other programming language you have only one way to pass variables into lambda scope. In C++ you can decide if variables should be passed as reference, or as value, or even you can decide which variables to include. The thing I hate in C++ the most are compilation errors. Sometimest just simple mistake generates thousands of lines of error report (especially on G++). And memory management is awesome on C++ (smart pointers)
No question C++ is powerful. There are many use-cases where you probably wouldn't want to go with any other language. It gives you lots of freedom, but this also leads to great responsibility. When I first learned c++, there were no smart pointers, lambdas, or anything like that.
I first learned Borland Turbo c++ around 1995. No fancy features back then! I was programming serial (and parallel port) communication back then! T
hat's why I'm amazed at how much the language has improved. Once ZapRead is more stable, I'll probably start some projects with embedded devices to hone my atrophied C++ skills :)
Back then I was using Turbo Pascal, as far as I remember it had similar text interface xD.. Btw - everything looked like Norton Commander
And that is true - I had few years of a break from C++. I came back to this language about 3 years ago and was amazed how it evolved (introduction of C++11).