std::transform_exclusive_scan
From cppreference.com
C++
Algorithm library