How many five digit numbers that have a nine and a six as the first and third digit are not divisible by 3? Please explain HOW you get your solution.
Let n=9a6bc be the number (decimal representation:base10). Let us find how many are divisible by 3 then we can subtract it from the total possible numbers to get the required answer. For divisibility by 3, 3 must divide 9+a+6+b+c or, 3 must divide a+b+c..
would that even work?
wat do u mean paulzord?
i was going to ask, howcome you only need a,b and c, but now that i read it again i think that should've been obvious
Isn't that brute forcing it? Would you have to try a lot of combinations to get the answer?
now possibilities (m is integer) {a,b,c}={3m,3m,3m},{3m+1,3m,3m+2}<--this one has 5 more combinations,{3m+1,3m+1,3m+1}. You have to vary m from 0,1,2,3 and do it for the above 8 combinations.
this problem needs some bruteforcing...:( no matter whatever method u try!
So the answer is 666? Cool! Thanks. I thought there was a way where it was all algebra and no bruteforcing but I guess I was wrong.
Join our real-time social learning platform and learn together with your friends!