Given , you need to find all pairs
such that:
One line contains one integer. (
)
In the first line, output the number of pairs
you found.
Then each line contains two integers, indicating
and
.
If there are multiple pairs
, you should output them in the increasing order.
if and only if
or (
and
).