last member of a list java code example
Example: java get last element of list
ArrayList<Integer> list = new ArrayList<Integer>(5);
int last = list.get(list.size() - 1);
ArrayList<Integer> list = new ArrayList<Integer>(5);
int last = list.get(list.size() - 1);