[TJOI 2019] sing, dance, rap and basketball

 The meaning of problems

  There $ A $ a $ 0 $, $ b $ a $ 1 $, $ c $ a $ 2 $, $ d $ a $ 3 $, find how many of length $ n-$ does not contain $ 0123 $ this substring of string a number.

  $ N \ the 1000 \ space a + b + c + d \ $ 500

 answer

 Push convolution equation 1

 

 The method of inclusion and exclusion 2

 Portal

 Made it clear that no further explanation

 

Guess you like

Origin www.cnblogs.com/scx2015noip-as-php/p/11299195.html