{
 "cells": [
  {
   "cell_type": "markdown",
   "id": "3a87d471",
   "metadata": {},
   "source": [
    "# Dictionaries & Sets"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "62c29df2",
   "metadata": {},
   "source": [
    "This chapter introduces two of Python's most powerful built-in data structures: **dictionaries** and **sets**.\n",
    "\n",
    "**Dictionaries** map keys to values, giving you fast lookup by name rather than by position. They are the foundation of many elegant algorithms — from counting word frequencies to building indexes and caches.\n",
    "\n",
    "**Sets** store unordered collections of unique elements. They support efficient membership testing and the classic mathematical operations — union, intersection, and difference — making them ideal for problems like deduplication and finding common elements.\n",
    "\n",
    "Topics covered in this chapter:\n",
    "\n",
    "| Data Structure | Topic | Description |\n",
    "|---|---|---|\n",
    "| **Dict** | Dictionary basics | Creating, accessing, and modifying key-value pairs |\n",
    "|    | Dictionary methods | `.keys()`, `.values()`, `.items()`, `.get()`, `.update()`, and more |\n",
    "|    | Dictionary comprehensions | Building dictionaries concisely with a single expression |\n",
    "|    | Counting & histograms | Using dictionaries to tally occurrences |\n",
    "| **Set** | Set basics | Creating sets and understanding unordered uniqueness |\n",
    "|        | Set operations | Union (`\\|`), intersection (`&`), difference (`-`), symmetric difference (`^`) |\n",
    "|    | Set comprehensions | Building sets concisely with a single expression |\n",
    "| Both | Choosing the right structure | When to use a list, dict, or set |"
   ]
  },
  {
   "cell_type": "markdown",
   "id": "109babbe",
   "metadata": {},
   "source": []
  }
 ],
 "metadata": {
  "language_info": {
   "name": "python"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
