Skip to content

Commit

Permalink
Create main.py
Browse files Browse the repository at this point in the history
  • Loading branch information
KOSASIH authored May 15, 2024
1 parent 21abd56 commit e636df5
Showing 1 changed file with 17 additions and 0 deletions.
17 changes: 17 additions & 0 deletions tools/examples/main.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import code_errors_fixer

code = """
def hello_world():
print("Hello, world!")
hello_world()
"""

errors = code_errors_fixer.find_syntax_errors(code)

if errors:
print("Syntax errors found:")
for error in errors:
print(error)
else:
print("No syntax errors found.")

0 comments on commit e636df5

Please sign in to comment.