Three computer scientists have solved a longstanding maths problem by creating a method for a computer to tell quickly and definitively whether a number is prime.

Current computer alogrithms are fast, but hae a small chance of giving either a wrong answer, or no answer at all. The new algorithm guarantees a correct and timely answer.

This comes as good news to computer scientists and mathematicians, since it simply and elegantly solves a problem that has challenged many in this field, for decades.

Here's the PDF file with the algo:

http://www.cse.iitk.ac.in/news/primality.pdf