Handle more cases and added an add() method to differ from set()