2017 ACM-ICPC 亚洲区(南宁赛区)网络赛 A Weather Patterns
Consider a system which is described at any time as being in one of a set of NN distinct states, 1,2,3,...,N1,2,3,...,N. We denote the time instants associated with state changes as t = 1,2,...t