Java Programming – Design a data structure that supports insert, delete, search and getRandom in constant time
The idea is to use a resizable array (ArrayList in Java, vector in C) together with hashing. Resizable arrays support insert in Θ(1)
Browsing Category