ArrayList has two methods named remove:
public Object remove(int index)
public boolean remove(Object o)
There is no remove that takes no arguments. If you want to remove the first elements, write queue.remove(0). Also, when adding elements, if you are adding to the end of the list, it simpler to write queue.add(car) and not worry about tracking the count. And speaking of the count, ArrayList has a size() method, so you may be duplicationg effort by mantaining a count field. Finally, given the name of your field -- queue -- and the fact that you seem to want a FIFO queue -- add to the back and remove from the front, it may make more sense to use java.util.LinkedList: it has method removeFirst (as well as addLast). And if you are using the current version of
Java, LinkedList implements a specific Queue interface, which you may be interested in.