A number theory problem by Quý Bùi Tứ
Without its cover, a thick book has n pages (from page 1 to page n) and each of these n pages shall have a page number on its corner.
To number all these pages, it is noticed that exactly 4n digits are used.
Find n. (Please do not concern whether n is odd or even. If n is odd, then page n+1 is left blank and does not have its page number.)