import java.util.Scanner; public class AddNum { public static void main(String[] args) { int sum = 0; int base = 1; Scanner sc = new Scanner(System.in); int x = sc.nextInt(); for (int i = x; i > 0; i–) { sum += Add(i, base); base *= 10; } System.out.println(sum); } public static int Add(int x, int y) { int sum = 0; sum += (2 * x * y); return sum; } }