java - Data Structure to store given data, search and remove operation should be efficient -
i working on project in java.
in project, first url web using jsoup.
now performance reason, have store
[ tag name, tag id, tag class name ]
in container, , known tag id either null or unique.
example,
["a", "fullsitelink", ""] ["div", "", "mob-footer"] ["div", "", "clear"] ["br", "", ""] ["ul", "", "mob-footer-links"]
so please tell me data structure stores these information every tag, , can search, remove tag in efficient way.
help me. in advance.
so please tell me data structure stores these information every tag, , can search, remove tag in efficient way.
i use hashmap. 1 of efficient data structures quick insertion, lookup, , removal.
if isn't suited intend search style, a binary tree flexible data structure o(log n) search, insertion, , removal.
Comments
Post a Comment