Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixed issues in main.py: corrected file reading, JSON writing, and fu… #221

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

DaJin-Kim
Copy link

Changes Made

  • Corrected file reading and stripping of newline characters in lines 5-8.
  • Improved JSON writing structure in lines 11-14 to ensure proper formatting.

Explanation

  1. Lines 5-8: The previous implementation did not strip newline characters from each line, which could lead to incorrect data formatting. I added list comprehensions to strip the newline characters.
  2. Lines 11-14: Ensured the JSON is properly formatted by adding an indent parameter to json.dump(), which makes the file more readable.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant