#P2568. Count of Prime GCD Pairs

    ID: 15837 Type: Default 1000ms 256MiB

Count of Prime GCD Pairs

Count of Prime GCD Pairs

Given a positive integer \(n\), count the number of pairs \((x, y)\) where \(1 \le x, y \le n\) such that \(\gcd(x, y)\) is a prime number.

inputFormat

The input consists of a single integer \(n\).

outputFormat

Output a single integer representing the number of pairs \((x, y)\) satisfying the condition.

sample

1
0