-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathread_dict.py
More file actions
38 lines (31 loc) · 758 Bytes
/
Copy pathread_dict.py
File metadata and controls
38 lines (31 loc) · 758 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
# path to word list in MacOS: /usr/share/dict/web2
#ObjRead = open("/usr/share/dict/web2", "r")
ObjRead = open("web2.txt", "r")
# txtContent = ObjRead.read();
#
# i=0
# for word in txtContent:
# i +=1
# print(len(word),hex(int(word)))
#
# print ("The Content of text file is : ", txtContent)
# print("number of words:",i)
#
#
#
#
variables = dict()
#with open('/usr/share/dict/web2', 'r') as textfile:
with open('web2.txt', 'r') as textfile:
while True:
next_line = textfile.readline()
print(next_line,len(next_line))
if len(next_line) == 0:
break
# key, value = next_line.split()
# if key == 'NODATA_value':
# break
#
# variables[key] = value
#
#ObjRead.close()