import java.util.*; public class Main { public static void main (String[] args) { Scanner sc = new Scanner(System.in); int n = sc.nextInt(); long left = 0; long right = 0; for (int i = 0; i < n; i++) { String str = sc.next(); if (str.contains(".")) { String leftString = str.substring(0, str.indexOf(".")); left += Long.parseLong(leftString); String rightString = str.substring(str.indexOf(".") + 1, str.length()); char[] arr = new char[10]; Arrays.fill(arr, '0'); for (int j = 0; j < rightString.length(); j++) { arr[j] = rightString.charAt(j); } long x = Long.parseLong(new String(arr)); if (str.charAt(0) == '-') { x *= -1; } right += x; } else { left += Long.parseLong(str); } } left += right / 10000000000L; right %= 10000000000L; if (right < 0) { if (left > 0) { left--; right += 10000000000L; } else if (left < 0) { right *= -1; } else { System.out.println("-0." + right * -1); return; } } System.out.println(left + "." + right); } }