Created
September 17, 2025 01:33
-
-
Save rlcarrca/72273f733beb04d74717aec92e0ec524 to your computer and use it in GitHub Desktop.
CSV to Excel
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
def csv_to_excel(csv_file, excel_file): | |
df = pd.read_csv(csv_file) | |
df.to_excel(excel_file, index=False) | |
# Usage | |
csv_to_excel('data.csv', 'data.xlsx') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment