Invitation to Mathemagic 2017- 24 Hour contest

Love solving Mathematical problems. Then get ready for some action ahead.

Computer Science Association, BITS PILANI, Pilani Campus presents you their flagship contest, “Mathemagic 2017”. It is being organised as a part of our technical fest, Apogee.

Contest Link :

Start Time : 17:00 IST, 23rd March’ 2017

Prizes to be Won:

First Place: INR 3000, Second Place: INR 2000, Third Place: INR 1000.

The contest consists of 10 problems of varying difficulty similar to ones available at Project Euler and ad Infinitum contests. The problems have been set such that even beginners can attempt a few problems and even the best coders find tough job ahead at the hard ones. Although Mathematical insights and tricks would help you find the logic in the problem, programming will be your way out for the full solution. There will be 4 “TEXT” based problems where the input is provided in the question, similar to the format in Project Euler. Rest 6 problems will be programming based. The editorials of all the problems with the Setter’s code will be uploaded immediately after the contest so that you may benefit from it.

The problems have been set by me. I would like to thank Morass for testing the problems and providing valuable feedback as well. I would also like to thank Chirag Agarwal and CSA juniors for their feedback as well.

To register for the contest, you just need a Hackerrank handle and then just click on the link mentioned above for registering for the contest.

I hope you enjoy the contest and Happy Coding :slight_smile:

UPDATE 1: Scoring & Type Distribution will be as follows:

  • 1: Easy 20 points (Text)

  • 2: Easy 30 points (Text)

  • 3: Medium 60 points (Programming)

  • 4: Medium 60 points (Text)

  • 5: Medium 80 points (Programming)

  • 6: Hard 100 points (Text)

  • 7: Hard 120 points (Programming)

  • 8: Advanced 150 points (Programming)

  • 9: Advanced 180 points (Programming)

  • 10: Advanced 200 points (Programming)

UPDATE2 : Contest is over and editorials are out. Winners will be announced soon after plagiarism check is over.

UPDATE3: The winners of the contest are uwi, jatin yadav and bayleef.


good one

yeah im ready…

Hyderabad campus gonna ace it! (I hope so…:p)

Yeah my favourite types of problems are these mathematical problems

1 Like

Your name kinda suggests that :stuck_out_tongue: @MATHEcodician

1 Like

lol. thanks.

1 Like

You can find below link of few questions set be me earlier:

  1. Codestorm Prelims 2016, Editorials can be found out here for more help.
  2. Problems at Spoj : 1 2 3
1 Like

What do you mean by “TEXT” type of problem? Will we have to solve a question as in exams?

The text type means the problems can only be submitted in text format. For arriving at the answer of the problem, either pen paper work or program can be used, as is the case in Project Euler problems. You will get to know more details during the contest.

Could someone who is not from India be eligible for the prize?

1 Like


very tough questions

thanks for the appreciation. Hope you will learn something from the editorials.

No Editorial for the question “Common Point”? I was really looking forward to it.

I will add it by today night as I am busy with other fest work now. BTW answer is ceil(n / (x-1)).

1 Like

Any comments regarding the feedback of contest, quality of problems and testcases, clarity of problem statements is welcomed.