Submission #716093

#TimeUsernameProblemLanguageResultExecution timeMemory
716093vjudge1Difference (POI11_roz)Cpython 3
30 / 100
1074 ms5876 KiB
n = int(input()) s = input() alph = "abcdefghijklmnopqrstuvwxyz" def m(s): max = 0 min = 10**7 for i in range(0, len(alph)): e=s.count(alph[i]) if e == 0: continue if e>max: max = e if e<min: min = e return max-min greatest = 0 for i in range(0, n): for j in range(i+1, n+1): r = m(s[i:j]) if r>greatest: greatest = r print(greatest)
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...
#Verdict Execution timeMemoryGrader output
Fetching results...