Algorithm, data structure and java coding.