Write a program that finds the number of triplets of integers
a
,
c
,
p
such that
p
— prime number, numbers satisfy the equality: $$ \sqrt{a} - \sqrt{c} = \sqrt{p}. $$ Each of the numbers
a
,
c
and
p
lies between
N
and
M code> (that is, \(N<=a<= M,\ N<=c<= M,\ N<=p<= M\)).
Input
Enter two integers N
and M
(\(0<=N<=M<=100000\) ).
Imprint
Output the desired number of triples of numbers a
, c
, p
.
Examples
# |
Input |
Output |
1 |
18 |
1 |
2 |
5 20 |
1 |
3 |
1 7 |
0 |