A source of confusion among developers is often centered around the flatmap and concatmap Operators. Their differences are really important and we will cover them in this section. Let's take a look at the flatmap operator and how it works:
//----------- Flatmap.cpp #include "rxcpp/rx.hpp" #include "rxcpp/rx-test.hpp" #include <ioStream> namespace rxu=rxcpp::util; #include <array> int main() { std::array< std::string,4 > a={{"Praseed", "Peter", "Sanjay","Raju"}}; //---------- Apply Flatmap on the array of names //---------- Flatmap returns an Observable<T> ( map returns T ) //---------- The First lamda creates a new Observable<T> //---------- The Second Lambda manipulates primary Observable ...