Caso # | Resultado | Tiempo | Memoria |
---|---|---|---|
#1 |
Correcto
|
0.025 s | 3 KBi |
#2 |
Correcto
|
0.023 s | 3 KBi |
#3 |
Correcto
|
0.044 s | 6 KBi |
#4 |
Correcto
|
0.029 s | 3 KBi |
#5 |
Correcto
|
0.024 s | 3 KBi |
#6 |
Correcto
|
0.018 s | 3 KBi |
#7 |
Correcto
|
0.051 s | 3 KBi |
#8 |
Correcto
|
0.051 s | 3 KBi |
#9 |
Correcto
|
0.052 s | 3 KBi |
#10 |
Correcto
|
0.054 s | 3 KBi |
#11 |
Correcto
|
0.052 s | 3 KBi |
#12 |
Correcto
|
0.057 s | 3 KBi |
#13 |
Incorrecto
|
0.054 s | 3 KBi |
#14 |
Correcto
|
0.06 s | 3 KBi |
#15 |
Correcto
|
0.053 s | 3 KBi |
#16 |
Correcto
|
0.072 s | 3 KBi |
#17 |
Correcto
|
0.054 s | 3 KBi |
#18 |
Correcto
|
0.044 s | 3 KBi |
#19 |
Correcto
|
0.047 s | 3 KBi |
#20 |
Correcto
|
0.047 s | 3 KBi |
#21 |
Correcto
|
0.06 s | 3 KBi |
#22 |
Correcto
|
0.058 s | 3 KBi |
def string_edge(s): size = 0 left_index = 0 for right_index in range(1, len(s)): left = s[left_index] right = s[right_index] if left_index > 0 and left != right: left_index = 0 left = s[left_index] if left == right: left_index += 1 size = left_index return size s = input() print(string_edge(s))