Hello,
To ensure the the files run error free on VS code, download the python-challenge folder as a zip. Unzip the folder to your local and open the folder in VS code.
Please find in this folder the following contents:
- PyBank Folder which contains main.py file
- PyPoll Folder which contains respective main.py file
- Analysis Folder contains both output info for PyBank & PyPoll in txt format
- Resources Folder which contains the budget and election data
References: How to read/write files in python: https://note.nkmk.me/en/python-csv-reader-writer/#read-csv-files-csvreader
How to output results in python: https://www.geeksforgeeks.org/reading-writing-text-files-python/
Using len function to count columns: https://www.quora.com/How-do-you-count-the-number-of-rows-in-a-CSV-file-in-Python
Dictionary & arrays to find winners in election: https://www.geeksforgeeks.org/dictionary-counter-python-find-winner-election/
How to get max candidate votes in python: https://chat.openai.com/share/a2585de4-2111-4009-a1a2-b880eb864cb5
How to read a csv file: read_file_solution.py that was discussed in our Class 2 of Python
Appending list columns in python: https://discuss.python.org/t/append-to-list-each-line-of-csv-file-row-if-row-is-have-numeric-values/19452
Python method of get and items to help calculate percentage candidate votes: https://www.programiz.com/python-programming/methods/dictionary/get
None type in python: https://note.nkmk.me/en/python-none-usage/