Name | Language | Tokens Sum | Tokens Part 1 | Tokens Part 2 | Last change | |
---|---|---|---|---|---|---|
1 | Python | 146 | 88 | 58 | 8 months ago | |
2 | Kotlin | 227 | 123 | 104 | 9 months ago | |
3 | Python | 313 | 170 | 143 | 8 months ago | |
4 | Kotlin | 404 | 221 | 183 | 8 months ago |
import
re
t
=
0
try
:
while
l
:=
input
(
)
:
p
=
0
,
0
,
0
for
w
in
l
.
split
(
"
;
"
)
:
f
=
lambda
c
,
j
:
max
(
int
(
re
.
search
(
f
"
(
\
d
+
)
{
c
}
"
,
w
)
[
1
]
)
if
c
in
w
else
0
,
p
[
j
]
)
p
=
f
(
"
r
"
,
0
)
,
f
(
"
g
"
,
1
)
,
f
(
"
b
"
,
2
)
t
+=
(
p
[
0
]
or
1
)
*
(
p
[
1
]
or
1
)
*
(
p
[
2
]
or
1
)
except
:
print
(
t
)