2889. Reshape Data: Pivot
\n# Code\npythondata []\nimport pandas as pd\n\ndef pivotTable(weather: pd.DataFrame) -> pd.DataFrame:\n    df = weather.pivot(index = "month", columns = "city"
\n# Code\n```pythondata []\nimport pandas as pd\n\ndef pivotTable(weather: pd.DataFrame) -> pd.DataFrame:\n    df = weather.pivot(index = "month", columns = "city", values = \'temperature\')\n\n    return df\n```
['Pandas']