Grafika saw an omoshiroi problem yesterday: give you a positive number , find the minimal prime number that , of cource, such prime number may not exist.
Problem G: 五队-大连-Minimum primeTime Limit: 1 Sec Memory Limit: 32 MB
Submit: 54 Solved: 12
There are multiple test cases. Given () as described before in one line. Process to end of file.
Print the prime number in one line. If such prime number doesn’t exist, print “-1” instead.
10 5 2
3 2 -1