def alphabetlist():
print("alphabet1 = [a,b,c,d,e,f]")
print("alphabet2 = [g,h,i,j,k,l]")
print("alphabet3 = [m,n,o,p,q,r]")
print("alphabet4 = [s,t,u,v,w,x]")
print("alphabet5 = [y,z]")
print("Guess a word.")
print("Now i will try to figure out the word you guessed.")
totalletters=int(input("total number of letters in your guessed words are: "))
def chooselist(x):
if x == 1:
print(alphabet1)
elif x == 2:
print(alphabet2)
elif x == 3:
print(alphabet3)
elif x == 4:
print(alphabet4)
elif x == 5:
print(alphabet5)
list=[ ]
def listtranspose(w):
if w == 1:
i=int(input());list.append(alphabet1[i-1])
elif w == 2:
i=int(input());list.append(alphabet2[i-1])
elif w == 3:
i=int(input());list.append(alphabet3[i-1])
elif w == 4:
i=int(input());list.append(alphabet4[i-1])
elif w == 5:
i=int(input());list.append(alphabet5[i-1])
alphabetlist()
alphabet1 = ["a","b","c","d","e","f"]
alphabet2 = ["g","h","i","j","k","l"]
alphabet3 = ["m","n","o","p","q","r"]
alphabet4 = ["s","t","u","v","w","x"]
alphabet5 = ["y","z"]
step_1=[ ];h=0
while totalletters>h:
print("your letter is from which list 1,2,3,4,5")
x = int(input())
step_1.append(x);h+=1
print("***\n 1 2 3 4 5 6 ")
g=0
while totalletters>g:
chooselist(step_1[g]);g+=1
print("*******");e=0
while totalletters>e:
print("choose from these lists again now 1,2,3,4,5,6")
listtranspose(step_1[e]);e+=1
print("the word you guessed is: ",end=" ")
for i in range(0,len(list),1):
print(list[i],end="")
This program is a word guessing game. The user thinks of a word and this program guesses it. through a series of list I want to know if there are other ways to write this, more easily actually I get all the functions used but not the next part