【发布时间】:2021-10-17 21:40:31
【问题描述】:
pat = "TATAG"
DSIGMA = 4 //i used 4 character 'ACGT'
m = len(pat)
string = "ACGT"
shift = [[0] * DSIGMA]*m
for l in range(m):
U[l] = 1
for s in range(DSIGMA):
shift[l][string[s]] = 1'''
Output
TypeError: 列表索引必须是整数或切片,而不是 str
I build this code in c++ and run perfectly, but when i convert into python it doesn't work. How to fix my code? Thanks!
【问题讨论】:
-
你好 Luqman,欢迎来到 stackoverflow :)
标签: python