Skip to content

Commit 43a5510

Browse files
authored
Update edit distance.py
1 parent bf6b1c1 commit 43a5510

File tree

1 file changed

+21
-1
lines changed

1 file changed

+21
-1
lines changed

edit distance.py

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,4 +28,24 @@ def edit(a,b):
2828

2929
return c[len_a][len_b]
3030

31-
print(edit('asdad','gadfasf'))
31+
import random as rd
32+
33+
34+
35+
temp=rd.randint(1,20)
36+
temp1=rd.randint(1,20)
37+
alphabet='abcdefghijklmnopqrstuvwxyz'
38+
temp2=''
39+
temp3=''
40+
41+
for n in range(temp):
42+
temp2+=alphabet[rd.randint(0,25)]
43+
44+
for o in range(temp1):
45+
temp3+=alphabet[rd.randint(0,25)]
46+
47+
48+
49+
50+
print(temp2,temp3)
51+
print(edit(temp2,temp3))

0 commit comments

Comments
 (0)