import java.util.LinkedHashMap;
import java.util.Map;

public class Main {
    public static void main(String[] args) {
        // Crear un LinkedHashMap
        LinkedHashMap<Integer, String> linkedHashMap = new LinkedHashMap<>();

        // Agregar elementos
        linkedHashMap.put(3, "Tres");
        linkedHashMap.put(1, "Uno");
        linkedHashMap.put(2, "Dos");

        // Mostrar elementos
        for (Map.Entry<Integer, String> entry : linkedHashMap.entrySet()) {
            System.out.println("Key: " + entry.getKey() + ", Value: " + entry.getValue());
        }
    }
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: