Ans 3: 4371 (if single and double digit numbers are excluded) and 4373 (if they are included).
My approach: Count numbers. Obviously we are looking for a maximum nine digit number. Approach is to find total numbers possible with certain number of digits first. Since every third number is divisible by 3, divide total number of certaindigit number by 3. Different cases are explained below.
Case 1: 9digit numbers  Total numbers  1 x 3^{8}; Requirement = 1 x 3^{7} = 2187.
Case 2: 8digit numbers  Total numbers  2 x 3^{7}; Requirement = 2 x 3^{6} = 1458.
Case 3: 7digit numbers  Total numbers  2 x 3^{6}; Requirement = 2 x 3^{5} = 486.
Case 4: 6digit numbers  Total numbers  2 x 3^{5}; Requirement = 2 x 3^{4} = 162.
Case 5 : 5digit numbers  Total numbers  2 x 3^{4}; Requirement = 2 x 3^{3} = 54.
Case 6 : 4digit numbers  Total numbers  2 x 3^{3}; Requirement = 2 x 3^{2} = 18.
Case 7 : 3digit numbers  Total numbers  2 x 3^{2}; Requirement = 2 x 3^{1} = 6.
Case 8 (Optinal) : 2digit numbers  Total numbers  2 x 3^{1}; Requirement = 2.
Case 9 (Optional) : 1digit numbers  Total numbers  2; Requirements = 0.
Total : 2187+1458+486+162+54+18+6 = 4371 (Excluding single and double digit number)
or 4371+2 = 4373 (including single and double digit numbers).
Please check for calculation mistakes, if any.
Himanshu Shekhar
