Bowl of Fruit - General Update Pattern Special Cases
The bowl of fruit demonstrates special cases of D3’s general update pattern, showing how enter, update, and exit selections handle data changes. Five apples are drawn as circles with text labels; then an apple is removed, another is swapped for a lemon, and a third is filtered out. The code uses `d3.selectAll`, `data`, `enter`, `merge`, and `exit` to manage SVG groups, with `scaleOrdinal` mapping fruit types to radii and colors. The animation runs via `setTimeout`, with each step re-rendering the bowl shape and fruit positions.