Q:

Returning first key of a LinkedHashMap

I have a LinkedHashMap in a class called Yoghurts
Map<Integer, Integer>French = new LinkedHashMap<Integer, Integer>();

I then made accessor methods, so that the collection could be accessed from another class
I now want to GET the first key entered, but I am not sure how to do this. 
 int location = Yoghurts.getHashMap().entrySet().iterator().next();

however this returns the error incompatible types

A:

The problem is that you're using entrySet(), whose members are of type Map.Entry<Integer,Integer>. Use getKey() on the result of the iterator, or use map.keySet().iterator().next();

