Author |
Topic: Number of block arrangements (Read 677 times) |
|
peninha
Newbie
Posts: 7
|
|
Number of block arrangements
« on: Mar 30th, 2010, 5:20am » |
Quote Modify
|
You are given N distinct blocks of height 1…N. In how many ways can you arrange these blocks in a row such that when viewed from left you see only L blocks (rest are hidden by taller blocks) and when seen from right you see only R blocks? Example given N=3, L=2, R=1 there is only one arrangement {2, 1, 3} while for N=3, L=2, R=2 there are two ways {1, 3, 2} and {2, 3, 1}.
|
|
IP Logged |
|
|
|
SMQ
wu::riddles Moderator Uberpuzzler
Gender:
Posts: 2084
|
|
Re: Number of block arrangements
« Reply #1 on: Mar 30th, 2010, 5:41am » |
Quote Modify
|
The search function is your friend: we discussed this earlier this month. --SMQ
|
|
IP Logged |
--SMQ
|
|
|
peninha
Newbie
Posts: 7
|
|
Re: Number of block arrangements
« Reply #2 on: Mar 30th, 2010, 5:43am » |
Quote Modify
|
Thanks, I missed that one
|
|
IP Logged |
|
|
|
|