psf/black code formatting (#1277)

This commit is contained in:
William Zhang
2019-10-05 01:14:13 -04:00
committed by Christian Clauss
parent 07f04a2e55
commit 9eac17a408
291 changed files with 6014 additions and 4571 deletions

View File

@ -41,12 +41,12 @@ def longest_common_subsequence(x: str, y: str):
for i in range(1, m + 1):
for j in range(1, n + 1):
if x[i-1] == y[j-1]:
if x[i - 1] == y[j - 1]:
match = 1
else:
match = 0
L[i][j] = max(L[i-1][j], L[i][j-1], L[i-1][j-1] + match)
L[i][j] = max(L[i - 1][j], L[i][j - 1], L[i - 1][j - 1] + match)
seq = ""
i, j = m, n
@ -69,9 +69,9 @@ def longest_common_subsequence(x: str, y: str):
return L[m][n], seq
if __name__ == '__main__':
a = 'AGGTAB'
b = 'GXTXAYB'
if __name__ == "__main__":
a = "AGGTAB"
b = "GXTXAYB"
expected_ln = 4
expected_subseq = "GTAB"