1

Recently I read about implementation of Arrays in JavaScript - homogeneous (for single type elements) vs heterogeneous (for huge and unpopulated arrays or for elements of different types).

I know pros and cons of both...

However a question arose in my mind. Some blog posts explaining those differences refer to heterogeneous arrays as to HashMaps, some say those are HashTables. I even saw a diagram that looked exactly like a Linked List...

Does it all depend on something? Is there a single answer to it? I'd love to be pointed to a creditable source.

justMe
  • 674
  • 7
  • 26
  • 2
    In computer science, generally Hash Map and Hash Table means the same thing. The only difference I know is in Java where you have `HashMap` and `Hashtable`; this difference doesn't exists in JS (since it hasn't such objects). It might not be a creditable source, but at least here you have some idea about it: https://en.wikipedia.org/wiki/Hash_table and https://stackoverflow.com/questions/40471/differences-between-hashmap-and-hashtable for java. – ZER0 Jul 16 '18 at 10:07
  • The first sentence was all I needed! :) So the difference only occurs in Java. It wouldn't make sense in JS, since its single threaded (we'll see what Node 10.50 and its extra threads has to say about it in future). Cheers man! – justMe Jul 16 '18 at 10:24

0 Answers0