Explanation:
40 pages is 40/400 = 1/10 of the whole book.
these 40 pages (or 1/10 of the book) he reads in 3 days.
the ratio of his reading speed is therefore
40 pages / 3 days = 40/3 pages/day
now, to show the ratio for the whole 400 pages we need multiply 40/3 by a factor to bring 40 to 400. and we need to multiply the denominator (bottom) by the same factor to keep the overall value of the ratio.
we know from above that this factor has to be 10.
so,
40/3 × 10/10 = 400/30
that means that he will need 30 days to read the whole book.