import java.math.BigInteger; import java.util.Arrays; import java.util.Scanner; public class Main { public static void main(String[] args) { new Main().run(); } void run() { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); if (!(1 <= n && n <= 1000)) throw new AssertionError(); double sum = 0; for (int i = 0; i < n; ++i) { double x = sc.nextDouble(); double a = sc.nextDouble(); if (!(Math.abs(a) <= 1 && 0 <= x && x <= 2 * Math.PI)) throw new AssertionError(); sum += a; } System.out.println(sum * Math.PI); } static void tr(Object... objects) { System.out.println(Arrays.deepToString(objects)); } }