C++ STL numeric - reduce (parallel fold) | Modern Cpp Series

Поділитися
Вставка
  • Опубліковано 9 кві 2024
  • ►Full C++ Series Playlist: • The C++ Programming La...
    ►Find full courses on: courses.mshah.io/
    ►Join as Member to Support the channel: / @mikeshah
    ►Lesson Description: In this lesson we take a look at std::reduce -- which has been around since C++ 17 and improves upon std::accumulate. This is a powerful algorithm that allows us to get the benefits of accumulate (i.e. fold) but also provide an execution policy for potential parallelism. Two 'gotcha's' remain 1. make s sure the initial type matches your result (as this is determined at compile-time by the template parameter type) 2. Make sure the default value for the constructed type is what you want it, if you choose the overload that omits 'init'. I'll show in this example how to think about 'parallel fold' operations.
    ►UA-cam Channel: / mikeshah
    ►Please like and subscribe to help the channel!
    ►Join our free community: courses.mshah.io/communities/...
  • Наука та технологія

КОМЕНТАРІ • 6

  • @weemanling
    @weemanling Місяць тому +1

    Phenomenal channel. I've never been able to grasp the concepts and language this easy before.

    • @MikeShah
      @MikeShah  Місяць тому

      Cheers, thank you for the kind words!

  • @guru_mahendrakar
    @guru_mahendrakar Місяць тому

    100 Videos Are Completed. This Is Complete Playlist or Not ( Because I'm New In C++ )

    • @MikeShah
      @MikeShah  Місяць тому +1

      There are more videos that will continue to come :)

    • @guru_mahendrakar
      @guru_mahendrakar Місяць тому +1

      @@MikeShah Thnx Sir.🙂 I Think This Playlist One Of The Best Playlist On UA-cam 🖤 ( Added In My Favourite`s One )

    • @MikeShah
      @MikeShah  Місяць тому

      @@guru_mahendrakar Cheers!