Math Quiz: New Tasks (29)

By NeZbiE

"Hey Adok, first of all I'd like to congratulate you on the great job your doing with Hugi, with its consistent quality and ease of use =)

I suppose there are quite a few math geeks like me out there in the scene, so I am offering what may become a math competition in every Hugi diskmag? I could create some logic problems for each issue, and the first to reply with correct answers gets special recognition =) If you worry about consistency, don't worry as I habitually create math problems all the time."

Well, here are two problems to start off. Note that all these problems can be solved using just pencil and paper, and don't require any higher math knowledge.

1. The numbers 1000 to 2004 are written consecutively to create a REALLY large integer: 100010011002....20032004. What is the largest power of 3 that divides this number?

2. Let us define set A such as A = {1,2,3...,2003,2004}. Let S be a strict subset of A. What is the largest possible cardinalty/size of set S, such that no two elements in S add up to a multiple of 7?
For example:
The subset {1,2,4,5} would not work, since 2+5 = 7.
{1,2,3,8,10} would work, since no two elements ad up to a multiple of 7.
{1,2,3,8,10,12} would not work since 12+2 = 14 = 7 * 2.
Note to Hugi readers: In case you haven't realized, doing this brute force is definitely not a good idea, even for coders =)