How many positive integers of n digits chosen from the set {2,3,7,9} are divisible by 3 ?? ...

How many positive integers of n digits chosen from the set {2,3,7,9} are divisible by 3 ?? ...

No vote yet

2 votes

×

Problem Loading...

Note Loading...

Set Loading...

## Comments

Sort by:

TopNewestThere is 1 integer congruent to 1, 1 congruent to 2, and 2 congruent to 0 mod 3. They are all non zero so that makes life easy on us. Define a(n), b(n) and c(n) as the number of positive integers with n digits congruent to 0,1,2 mod 3, respectively.

a(1) = 2, b(1) = 1, c(1) = 1

a(n+1) = 2a(n) + b(n) + c(n)

b(n+1) = c(n+1) = 2b(1) + c(1) + a(1)

a(2) = 6, b(2) = c(2) = 5

a(3) = 22, b(3) = c(3) = 21

This suggests that a(n) = b(n) + 1 = c(n) + 1, which is easy to prove by induction (i'll leave the proof to you).

The resulting answer would then be a(n) = ((4^n)+2)/3 – Gabriel Wong · 4 years, 2 months ago

Log in to reply

3 and 9 are divisible – Anshul Agarwal · 4 years, 2 months ago

Log in to reply

2, because 3 and 9 are divisible by 3 whereas 2 and 7 are not.

You're welcome! – Tim Ye · 4 years, 2 months ago

Log in to reply

3 and 9 – Vipin Tiwari · 4 years, 2 months ago

Log in to reply

y el 27? – Jemisson Coronel Baldeón · 4 years, 2 months ago

Log in to reply