Function to calculate the number of trees with exactly k leaves .
int k_Leaves ( int n , int k ) { int ans = ( binomialCoeff ( n , k ) * binomialCoeff ( n , k - 1 ) ) / n ; cout << " Number ▁ of ▁ trees ▁ having ▁ 4 ▁ edges " << " ▁ and ▁ exactly ▁ 2 ▁ leaves ▁ : ▁ " << ans << endl ; return 0 ; }