Great explanation. My slightly improved (IMHO) version : def subsequence(string): result = [] l = len(string) if l == 0: result.append(" ") return(result) else: for i in subsequence(string[1:l]): result.append(i) result.append(string[0]+i) return(result)
Please explain about the problem statement first and them go to soln. The explanation was great but I didn't understand what we wanted to solve in first place
at 1:26 , "ac" should be used instead "ca" for maintaining relative position order
Great explanation. My slightly improved (IMHO) version :
def subsequence(string):
result = []
l = len(string)
if l == 0:
result.append(" ")
return(result)
else:
for i in subsequence(string[1:l]):
result.append(i)
result.append(string[0]+i)
return(result)
Great explanation.......please keep posting such videos
You are the best. Thank you
Thank you too!
Please explain about the problem statement first and them go to soln. The explanation was great but I didn't understand what we wanted to solve in first place
Uler tree se kiya hai apne basicly esko print bhi ker sakte hai and also get bhi ker sakte hai
Thank you for this
a="TANUJ"
li=[]
for i in range(0,len(a)):
for j in range(i+1,len(a)+1):
li.append(a[i:j])
print(li)
a="TANUJ"
li=[]
for i in range(0,len(a)):
for j in range(i+1,len(a)+1):
li.append(a[i:j])
print(li)
answer:-['T', 'TA', 'TAN', 'TANU', 'TANUJ', 'A', 'AN', 'ANU', 'ANUJ', 'N', 'NU', 'NUJ', 'U', 'UJ', 'J']
Plzz mam solve the count and say problem in Python.......