We have 40 sticks of same widths but different heights. How many arrangements are there possible to put them next to each other so that when we look from right we see 10 sticks and when we look from left we again see exactly 10 sticks?
For example such an ordering is:
Black sticks are hidden, red sticks are the ones you can see when you look from left, the blue sticks are the ones you can see when you look from right and purple one(i.e. the longest one) is the one that can be see seen from both sides.
As test cases:
- If we had 3 sticks number of orderings to see 2 from left and 2 from right is 2
- If we had 5 sticks number of orderings to see 3 from left and 3 from right is 6
- If we had 10 sticks number of orderings to see 4 from left and 4 from right is 90720