A 10-digit number is called beautiful if the digits 0, 1, 2, 3, 4 appear in ascending order, and the digits 9, 8, 7, 6, 5 appear in descending order.
If 0 can't be the first digit, how many beautiful numbers exist?
Note: As an explicit example, 9018762354 is beautiful because the 2 sequences appear in order, as evidenced by .
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
Simply, algorithm I used for this prob is -> UNIVERSE - EXCEPTION
Which is : (10C5) - (9C5) = 126
10C5 is the total number of position could obtained.
Then, 9C4 is the number of position which the 1st digit is 0. So we just need to find how to place the rest 4 digits there.