I have a HashMap called List wordFreqMap whose size is 234
HashMap
List wordFreqMap
size
234
wordFreqMap = {radiology
You are doing integer division and then casting that answer to a double. What you need to do is cast one of the two values to a double first, and then do division on it. That should get you the answer you desire.