摘要:
不合适的写法List<User> userList = new ArrayList<User>();for (int i = 0; i < 10; i++) { User user = new User(); user.setUpdatetime(new Date()); user.setUsername("test" + i); userList.add(user);}合适的写法User user = null;List<User> userList = new ArrayList<User>();for (int i 阅读全文