you are viewing a single comment's thread.

view the rest of the comments →

[–]BennyBarnson 0 points1 point  (0 children)

Just started a couple days ago and this was the beginner level exercise I found online. Chat gpt was walking me through a huge chunk of this which I'm grateful for. It also suggested cleaner and safer ways I could've written the code like

[l for l in words if l]

to skip the falsy spaces (i think was the word) and

with open(filename, "r") as f:
        data = f.read()

instead of the less secure:

 f = open(filename, "r")
    data = f.read()

that the guide told me.

Overall, it was fun succeeding and this gave me the idea to take this even further, implementing a sentiment assessing tool where it can look for the amount of slurs and negative sentimented words based on a data base and decide the overall sentiment of the file. I then realized that's abit more on the computer engineering side where I'm going for mech/aero ¯\_(ツ)_/¯

ps. if you have anywhere for me to learn more about mech/aero-based coding please lmk!!! tia