cocktail and bubble in js