Skip to content

Instantly share code, notes, and snippets.

View dippyshere's full-sized avatar
:octocat:
HubGit

Alex Hanson dippyshere

:octocat:
HubGit
View GitHub Profile
@dippyshere
dippyshere / oututconverter.py
Created November 15, 2022 14:48
convert txt list to py list without duplicates
# Takes an input txt file with items separated by a newline and outputs a python list of the items without duplicates
# open txt file and convert to list
with open("input.txt") as f:
content = f.read().splitlines()
# remove duplicates
seen = set()
result = []
for item in content: