Java, J2EE, SQL, Frameworks, APIs, Exceptions and more..
Pages
(Move to ...)
Home
About
Guest Post
▼
Monday, July 30, 2018
Binary tree - DFS and BFS
›
Depth first search In depth first search (dfs) you start with a root node and keep on traversing left node (or right node) until you rea...
Thursday, July 26, 2018
Least Recently Used (LRU) cache
›
Below java code is a simple implementation of Least Recently Used (LRU) cache using HashMap and LinkedList. For simplicity i am taking [I...
Wednesday, July 25, 2018
Simple junit test case with mockito
›
Mocking is a way to test the functionality of a class in isolation. Mockito facilitates creating mock objects seamlessly. It uses Java Refl...
Find a pair of elements from an array whose sum equals to a given number
›
The best way would be to insert every element into a hashset. Then for every x, we can just look up its complement, T-x. Overall the Time ...
Simple block chain code with Java
›
A blockchain is the structure of data that represents a financial ledger entry, or a record of a transaction. Block chain contains list of ...
‹
›
Home
View web version