자료구조 직접 구현 해보기3 - LinkedList ( Feat. Java)

이번에는, LinkedList를 직접 구현해 보았다.
역시 ForEach문을 사용할 수 있도록 Iterable 인터페이스를 상속받았다.
add, 특정위치 add, addFirst, addLast, remove, 특정위치 remove,
같은 오브젝트 전체 remove, removeFirst, removeLast, get, size, clear 의 기능들을 구현해보았다.

index 값과 size에 따라
NagativeArraySizeException, IndexOutOfBoundsException, NoSuchElementException
을 던지도록 구현했다.

댓글

이 블로그의 인기 게시물

About Kafka Basic

About JVM Warm up

About idempotent

About G1 GC

About ZGC

Spring Boot Actuator readiness, liveness probes on k8s

sneak peek jitpack

Optimistic Concurrency Control VS Pessimistic Concurrency Control - What should i choose?

DDD(Domain Driven Design) - Aggregate (어그리게잇)

Strategy Pattern In Spring (feat. JPA)