The code you have is commented. This will make it easier for you to be familiar with just what the code does and you will always have an entire notion of each par
Since then I have employed C++ to conduct numerical simulations as part of my physics exploration. I also participated in Advent of Code making use of C++.