// Collection of code snippets by Arne Vajhøj 
// (from articles on eksperten.dk / vajhoej.dk written sometime between 2004 and now) 
import java.util.ArrayList;
import java.util.List;

public class SeqCol21 {
    public static void main(String[] args) {
        List<Integer> lst = new ArrayList(List.of(1, 2, 3));
        lst.removeFirst();
        lst.addLast(4);
        System.out.printf("lst : %d .. %d\n", lst.getFirst(), lst.getLast());
    }
}

