Skip to content

Commit

Permalink
Розподіл спеціальності і вимог до неї
Browse files Browse the repository at this point in the history
  • Loading branch information
anastasiiaMirovska committed Jul 29, 2023
1 parent adfa26c commit afd3609
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions backend/split.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
with open('D:\YEP\Lighthouse\data.txt', 'r', encoding='UTF-8') as file:
content = file.read()
lines = content.split(";")
list_of_requirements = []
for i in range(0,len(lines)):
dictionary = {}
separate_words = []
requirements = []
line = lines[i]
separate_words = line.split(",")
name = separate_words[0]
for n in range( 0 , len(separate_words)):
if n >=1:
requirements.append(separate_words[n])
dictionary.update({name: requirements})
list_of_requirements.append(dictionary)

#dictionary.update(separate_words[i][1] : )

0 comments on commit afd3609

Please sign in to comment.