I'm really confused with the question below.
A phone number is a 7-digit sequence that does not start with 0.
(a) Call a phone number lucky if its digits are in non-decreasing order. For example, 1112234 is lucky, but 1112232 is not. How many lucky phone numbers are there?
(b) A phone number is very lucky if its digits are strictly increasing, such as with 1235689. How many very lucky phone numbers are there?
I have learnt that to determine if a question is asking for permutations or combinations we see if the order matters. For part a) it's talking about the order of these numbers and how many of these exist. In my head, permutations pop up and I would say the first position has 9 possibilities and so do the rest (if repeated). This is my same logic in part b). However, they are wrong and I do not understand how to proceed with this question. Please give some helpful tips when solving such problems.
You can do this with a kind of stars and bars method. Let's line up all the digits (except $0$):
$123456789$
These are like the 'stars'
Now, to represent a number like $1112234$ we can place the following $7$ bars:
$1|||2||3|4|56789$
(that is, we place a bar after the digit we're using)
Note that there will never be a bar before the $1$, so we can ignore that:
$|||2||3|4|56789$
Each different placement of the bars uniquely represents a lucky number, since you simply lists the digits by looking at the bars from left to right. For example:
$|2|3|45|6|78|9|$
would represent the 'very lucky' number $1235689$
So ... with this representation, how many lucky numbers are there?
OK, but what about 'very lucky numbers'?