Advertisement
Guest User

Untitled

a guest
Jun 24th, 2019
91
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.28 KB | None | 0 0
  1.  
  2. template<int N> struct F{
  3.     static const long v = N * F<N-1>::v;
  4. };
  5.  
  6. template<> struct F<0>{
  7.     static const long v = 1;
  8. };
  9.  
  10. which technique is used in this code snippet
  11.  
  12. 1 inheritance
  13. 2 meta programming
  14. 3 recursive function call
  15. 4 template specialization
  16. 5 Lambda
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement