Caso # | Resultado | Tiempo | Memoria |
---|---|---|---|
#1 |
Correcto
|
0.013 s | 3 KBi |
#2 |
Correcto
|
0.015 s | 3 KBi |
#3 |
Correcto
|
0.017 s | 3 KBi |
#4 |
Correcto
|
0.012 s | 3 KBi |
#5 |
Correcto
|
0.016 s | 3 KBi |
#6 |
Correcto
|
0.015 s | 3 KBi |
#7 |
Correcto
|
0.015 s | 3 KBi |
#8 |
Correcto
|
0.015 s | 3 KBi |
#9 |
Correcto
|
0.015 s | 3 KBi |
#10 |
Correcto
|
0.012 s | 3 KBi |
#11 |
Incorrecto
|
0.015 s | 3 KBi |
#12 |
Correcto
|
0.018 s | 3 KBi |
#13 |
Incorrecto
|
0.012 s | 3 KBi |
#14 |
Correcto
|
0.015 s | 3 KBi |
#15 |
Incorrecto
|
0.013 s | 3 KBi |
#16 |
Correcto
|
0.016 s | 3 KBi |
#17 |
Incorrecto
|
0.016 s | 3 KBi |
#18 |
Correcto
|
0.021 s | 3 KBi |
#19 |
Correcto
|
0.014 s | 3 KBi |
n_edificios = int(input()) alturas = list(map(int,list(input().split()))) arr=[] k = 1 for x in range(n_edificios): base = 1 altura_def= alturas[x] for i in range(len(alturas)-k): if(alturas[x]<=alturas[i+k]): base +=1 else: break arr.append(int(base)*int(altura_def)) k=k+1 print(int(max(arr)))