This question evaluates tree algorithms, hierarchical data modeling, concurrency and thread-safety, and test-driven development by requiring lowest common ancestor computation, a clear tree representation, unit tests, and support for dynamic additions and deletions.
Given an organizational hierarchy tree, return the lowest common organization (parent node) for two or more employees (≥ 2). Provide unit tests, detail your tree representation, and discuss how to support dynamic additions and deletions of users/groups with thread-safety considerations.