I know a bit of c++ and I have started taking part in some competitive programming contests. Many a times we are said to show the output modulo 109+7. However, I don't understand what's so special about this number. I have observed that this is used when the answer becomes large to handle. I want to know why this specific number only and not something else?
Edit: Sample question : https://www.codechef.com/FEB12/problems/WCOUNT
ANSWER : The number is a large prime number. Taking modulo takes care of the fact that the answer can be stored so that it stays within the limits of the size of the variable type