import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { static long maximumPeople(long[] p, long[] x, long[] y, long[] r) { // Return the maximum number of people that will be in a sunny town after removing exactly one cloud. long populationCloud[] = new long[y.length]; long cloudPerCity[] = new long[x.length]; long maxCloud[] = new long[y.length]; long maxPopulation=0; for(int i=0;i (y[j] - r[j]) && x[i] < (y[j] - r[j])) { cloudPerCity[i]++; populationCloud[j] += p[i]; } } } for(int i=0;i (y[j] - r[j]) && x[i] < (y[j] - r[j]) && cloudPerCity[i] > 1) { populationCloud[j] -= p[i]; } } } long number = populationCloud[0]; for(int i=1;i