Driver code
int main ( ) { Pair arr [ ] = { { 5 , 24 } , { 15 , 25 } , { 27 , 40 } , { 50 , 60 } } ; int n = sizeof ( arr ) / sizeof ( arr [ 0 ] ) ; cout << " Length ▁ of ▁ maximum ▁ size ▁ chain ▁ is ▁ " << maxChainLength ( arr , n ) ; return 0 ; }