Little C++ Standard Library Utility: std::align
I recently learned about std::align , one of the lesser-known functions in the C++ standard library due to its limited use cases. Since it is hard to describe without a specific use case, I will use…
I recently learned about std::align , one of the lesser-known functions in the C++ standard library due to its limited use cases. Since it is hard to describe without a specific use case, I will use…
This year is my first year doing the Advent of Code challenge, and today (2021 Day 7)'s challenge is a fun one. I won't go to the details, but the problem involves finding the minimum for a function…
Since the advent of C++14, we can create lambda expressions that take auto parameters. And in C++20, we can even do the same thing for regular functions. With this feature's advent, the programming…
I am doing some peer programming for a university course project today. In our codebase, we have a Ship class like the following: Later, the new requirement of the course project requires us to add…
Yesterday, someone in the #include<C++> discord server asked the following question: how std::function works with lambda captures and functions handling I still don't understand Below was my…