here is the question.

The number 916238457 is an example of a nine-digit number which
contains each of the digits 1 to 9 exactly once. It also has the property
that the digits 1 to 5 occur in their natural order,while the digits 1
to 6 do not. How many such numbers are there?
now I have tried to simplify the problem for my self by removing the last clause. In that case I believe that there will be 9!/5! such numbers (is that correct?).

I am having difficult implementing the last clause to get a complete solution.

all help is appreciated. Thank you in advance.

2. I am still unsure how to read the meaning of your question.
Do you mean that only the five digits are in correct order?
Or would you count 129348567 because the first seven are correct?

3. no i would not count 129348567 as the question states that the numbers 1 to 6 are not the their correct natural order and in this case they clearly are.

4. O.K. then.
Think of _1_2_3_4_5. We can put the ‘6’ in any of those places. That is 5 ways.
Say we choose _1_2_6_3_4_5_. Now there are seven places to put the ‘7’. That is 7 ways.
There are then 8 ways to put the ‘8’ and then nine ways to place the ‘9’.
What is the total number of ways?

5. 2520 ways