import java.util.*; public class Main{ public static void main(String[] args){ Scanner in = new Scanner(System.in); while(in.hasNext()){ //根据输入计算sum3,sum5和所有数总和sum,同时把不是5和3倍数的剩余数放入集合 List list = new LinkedList<>(); int n = in.nextInt(); int sum5=0, sum3=0, sum = 0; for (int i = 0; i < n; i+...