collections: SequencedDemo put through the reversed view now actually breaks the order (zed=60)

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01KqJyCidz3ZgRyHABv2GVJh
This commit is contained in:
Claude
2026-09-30 19:12:32 +00:00
parent 381f119308
commit f4b732799d
3 changed files with 6 additions and 6 deletions
@@ -27,7 +27,7 @@ public class SequencedDemo {
System.out.println("top2 (by pos) : " + top2);
// Because it is a view, writes show through.
asc.reversed().put("zed", 99);
asc.reversed().put("zed", 60);
System.out.println("after put via view (no longer sorted): " + asc);
// Re-ordering an existing LinkedHashMap: putLast moves an existing key to the end.