Skip to main content
Journey Uncommon Logo
JourneyUncommon
mediumC++generic lambdasSingle-choice MCQ

What does this generic (templated) lambda deduce and print?

#include <iostream> auto f = [](auto&& x) -> decltype(auto) { return std::forward<decltype(x)>(x); }; int main() { int a = 5; std::cout << std::is_lvalue_reference_v<decltype(f(a))>; }