¿La página no carga? Prueba haciendo clic aquí.
Placeholder

#3877

Secret Code 1s 128MB

Problemas


Entrada

* Line 1: A single encrypted string of length at most 100.


Salida

* Line 1: The number of ways FJ could have produced this string with one or more successive operations applied to some initial string of length at least 2, written out modulo 2014. If there are no such ways, output zero.


Ejemplo

ABABA 
8 

Fuente

USACO 2014 February Silver

Debes iniciar sesión para escribir código.