***************************************************************************** * www.FindStat.org - The Combinatorial Statistic Finder * * * * Copyright (C) 2019 The FindStatCrew * * * * This information is distributed in the hope that it will be useful, * * but WITHOUT ANY WARRANTY; without even the implied warranty of * * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. * ***************************************************************************** ----------------------------------------------------------------------------- Statistic identifier: St000807 ----------------------------------------------------------------------------- Collection: Integer compositions ----------------------------------------------------------------------------- Description: The sum of the heights of the valleys of the associated bargraph. Interpret the composition as the sequence of heights of the bars of a bargraph. A valley is a contiguous subsequence consisting of an up step, a sequence of horizontal steps, and a down step. This statistic is the sum of the heights of the valleys. ----------------------------------------------------------------------------- References: [1] Deutsch, E., Elizalde, S. A bijection between bargraphs and Dyck paths [[arXiv:1705.05984]] ----------------------------------------------------------------------------- Code: def statistic(c): v = 0 found_DH = False for i in range(1,len(c)): if found_DH: if c[i] > c[i-1]: found_DH = False v += c[i-1] else: if c[i] < c[i-1]: found_DH = True return v ----------------------------------------------------------------------------- Statistic values: [1] => 0 [1,1] => 0 [2] => 0 [1,1,1] => 0 [1,2] => 0 [2,1] => 0 [3] => 0 [1,1,1,1] => 0 [1,1,2] => 0 [1,2,1] => 0 [1,3] => 0 [2,1,1] => 0 [2,2] => 0 [3,1] => 0 [4] => 0 [1,1,1,1,1] => 0 [1,1,1,2] => 0 [1,1,2,1] => 0 [1,1,3] => 0 [1,2,1,1] => 0 [1,2,2] => 0 [1,3,1] => 0 [1,4] => 0 [2,1,1,1] => 0 [2,1,2] => 1 [2,2,1] => 0 [2,3] => 0 [3,1,1] => 0 [3,2] => 0 [4,1] => 0 [5] => 0 [1,1,1,1,1,1] => 0 [1,1,1,1,2] => 0 [1,1,1,2,1] => 0 [1,1,1,3] => 0 [1,1,2,1,1] => 0 [1,1,2,2] => 0 [1,1,3,1] => 0 [1,1,4] => 0 [1,2,1,1,1] => 0 [1,2,1,2] => 1 [1,2,2,1] => 0 [1,2,3] => 0 [1,3,1,1] => 0 [1,3,2] => 0 [1,4,1] => 0 [1,5] => 0 [2,1,1,1,1] => 0 [2,1,1,2] => 1 [2,1,2,1] => 1 [2,1,3] => 1 [2,2,1,1] => 0 [2,2,2] => 0 [2,3,1] => 0 [2,4] => 0 [3,1,1,1] => 0 [3,1,2] => 1 [3,2,1] => 0 [3,3] => 0 [4,1,1] => 0 [4,2] => 0 [5,1] => 0 [6] => 0 [1,1,1,1,1,1,1] => 0 [1,1,1,1,1,2] => 0 [1,1,1,1,2,1] => 0 [1,1,1,1,3] => 0 [1,1,1,2,1,1] => 0 [1,1,1,2,2] => 0 [1,1,1,3,1] => 0 [1,1,1,4] => 0 [1,1,2,1,1,1] => 0 [1,1,2,1,2] => 1 [1,1,2,2,1] => 0 [1,1,2,3] => 0 [1,1,3,1,1] => 0 [1,1,3,2] => 0 [1,1,4,1] => 0 [1,1,5] => 0 [1,2,1,1,1,1] => 0 [1,2,1,1,2] => 1 [1,2,1,2,1] => 1 [1,2,1,3] => 1 [1,2,2,1,1] => 0 [1,2,2,2] => 0 [1,2,3,1] => 0 [1,2,4] => 0 [1,3,1,1,1] => 0 [1,3,1,2] => 1 [1,3,2,1] => 0 [1,3,3] => 0 [1,4,1,1] => 0 [1,4,2] => 0 [1,5,1] => 0 [1,6] => 0 [2,1,1,1,1,1] => 0 [2,1,1,1,2] => 1 [2,1,1,2,1] => 1 [2,1,1,3] => 1 [2,1,2,1,1] => 1 [2,1,2,2] => 1 [2,1,3,1] => 1 [2,1,4] => 1 [2,2,1,1,1] => 0 [2,2,1,2] => 1 [2,2,2,1] => 0 [2,2,3] => 0 [2,3,1,1] => 0 [2,3,2] => 0 [2,4,1] => 0 [2,5] => 0 [3,1,1,1,1] => 0 [3,1,1,2] => 1 [3,1,2,1] => 1 [3,1,3] => 1 [3,2,1,1] => 0 [3,2,2] => 0 [3,3,1] => 0 [3,4] => 0 [4,1,1,1] => 0 [4,1,2] => 1 [4,2,1] => 0 [4,3] => 0 [5,1,1] => 0 [5,2] => 0 [6,1] => 0 [7] => 0 [1,1,1,1,1,1,1,1] => 0 [1,1,1,1,1,1,2] => 0 [1,1,1,1,1,2,1] => 0 [1,1,1,1,1,3] => 0 [1,1,1,1,2,1,1] => 0 [1,1,1,1,2,2] => 0 [1,1,1,1,3,1] => 0 [1,1,1,1,4] => 0 [1,1,1,2,1,1,1] => 0 [1,1,1,2,1,2] => 1 [1,1,1,2,2,1] => 0 [1,1,1,2,3] => 0 [1,1,1,3,1,1] => 0 [1,1,1,3,2] => 0 [1,1,1,4,1] => 0 [1,1,1,5] => 0 [1,1,2,1,1,1,1] => 0 [1,1,2,1,1,2] => 1 [1,1,2,1,2,1] => 1 [1,1,2,1,3] => 1 [1,1,2,2,1,1] => 0 [1,1,2,2,2] => 0 [1,1,2,3,1] => 0 [1,1,2,4] => 0 [1,1,3,1,1,1] => 0 [1,1,3,1,2] => 1 [1,1,3,2,1] => 0 [1,1,3,3] => 0 [1,1,4,1,1] => 0 [1,1,4,2] => 0 [1,1,5,1] => 0 [1,1,6] => 0 [1,2,1,1,1,1,1] => 0 [1,2,1,1,1,2] => 1 [1,2,1,1,2,1] => 1 [1,2,1,1,3] => 1 [1,2,1,2,1,1] => 1 [1,2,1,2,2] => 1 [1,2,1,3,1] => 1 [1,2,1,4] => 1 [1,2,2,1,1,1] => 0 [1,2,2,1,2] => 1 [1,2,2,2,1] => 0 [1,2,2,3] => 0 [1,2,3,1,1] => 0 [1,2,3,2] => 0 [1,2,4,1] => 0 [1,2,5] => 0 [1,3,1,1,1,1] => 0 [1,3,1,1,2] => 1 [1,3,1,2,1] => 1 [1,3,1,3] => 1 [1,3,2,1,1] => 0 [1,3,2,2] => 0 [1,3,3,1] => 0 [1,3,4] => 0 [1,4,1,1,1] => 0 [1,4,1,2] => 1 [1,4,2,1] => 0 [1,4,3] => 0 [1,5,1,1] => 0 [1,5,2] => 0 [1,6,1] => 0 [1,7] => 0 [2,1,1,1,1,1,1] => 0 [2,1,1,1,1,2] => 1 [2,1,1,1,2,1] => 1 [2,1,1,1,3] => 1 [2,1,1,2,1,1] => 1 [2,1,1,2,2] => 1 [2,1,1,3,1] => 1 [2,1,1,4] => 1 [2,1,2,1,1,1] => 1 [2,1,2,1,2] => 2 [2,1,2,2,1] => 1 [2,1,2,3] => 1 [2,1,3,1,1] => 1 [2,1,3,2] => 1 [2,1,4,1] => 1 [2,1,5] => 1 [2,2,1,1,1,1] => 0 [2,2,1,1,2] => 1 [2,2,1,2,1] => 1 [2,2,1,3] => 1 [2,2,2,1,1] => 0 [2,2,2,2] => 0 [2,2,3,1] => 0 [2,2,4] => 0 [2,3,1,1,1] => 0 [2,3,1,2] => 1 [2,3,2,1] => 0 [2,3,3] => 0 [2,4,1,1] => 0 [2,4,2] => 0 [2,5,1] => 0 [2,6] => 0 [3,1,1,1,1,1] => 0 [3,1,1,1,2] => 1 [3,1,1,2,1] => 1 [3,1,1,3] => 1 [3,1,2,1,1] => 1 [3,1,2,2] => 1 [3,1,3,1] => 1 [3,1,4] => 1 [3,2,1,1,1] => 0 [3,2,1,2] => 1 [3,2,2,1] => 0 [3,2,3] => 2 [3,3,1,1] => 0 [3,3,2] => 0 [3,4,1] => 0 [3,5] => 0 [4,1,1,1,1] => 0 [4,1,1,2] => 1 [4,1,2,1] => 1 [4,1,3] => 1 [4,2,1,1] => 0 [4,2,2] => 0 [4,3,1] => 0 [4,4] => 0 [5,1,1,1] => 0 [5,1,2] => 1 [5,2,1] => 0 [5,3] => 0 [6,1,1] => 0 [6,2] => 0 [7,1] => 0 [8] => 0 [1,1,1,1,1,1,1,1,1] => 0 [1,1,1,1,1,1,1,2] => 0 [1,1,1,1,1,1,2,1] => 0 [1,1,1,1,1,1,3] => 0 [1,1,1,1,1,2,1,1] => 0 [1,1,1,1,1,2,2] => 0 [1,1,1,1,1,3,1] => 0 [1,1,1,1,1,4] => 0 [1,1,1,1,2,1,1,1] => 0 [1,1,1,1,2,1,2] => 1 [1,1,1,1,2,2,1] => 0 [1,1,1,1,2,3] => 0 [1,1,1,1,3,1,1] => 0 [1,1,1,1,3,2] => 0 [1,1,1,1,4,1] => 0 [1,1,1,1,5] => 0 [1,1,1,2,1,1,1,1] => 0 [1,1,1,2,1,1,2] => 1 [1,1,1,2,1,2,1] => 1 [1,1,1,2,1,3] => 1 [1,1,1,2,2,1,1] => 0 [1,1,1,2,2,2] => 0 [1,1,1,2,3,1] => 0 [1,1,1,2,4] => 0 [1,1,1,3,1,1,1] => 0 [1,1,1,3,1,2] => 1 [1,1,1,3,2,1] => 0 [1,1,1,3,3] => 0 [1,1,1,4,1,1] => 0 [1,1,1,4,2] => 0 [1,1,1,5,1] => 0 [1,1,1,6] => 0 [1,1,2,1,1,1,1,1] => 0 [1,1,2,1,1,1,2] => 1 [1,1,2,1,1,2,1] => 1 [1,1,2,1,1,3] => 1 [1,1,2,1,2,1,1] => 1 [1,1,2,1,2,2] => 1 [1,1,2,1,3,1] => 1 [1,1,2,1,4] => 1 [1,1,2,2,1,1,1] => 0 [1,1,2,2,1,2] => 1 [1,1,2,2,2,1] => 0 [1,1,2,2,3] => 0 [1,1,2,3,1,1] => 0 [1,1,2,3,2] => 0 [1,1,2,4,1] => 0 [1,1,2,5] => 0 [1,1,3,1,1,1,1] => 0 [1,1,3,1,1,2] => 1 [1,1,3,1,2,1] => 1 [1,1,3,1,3] => 1 [1,1,3,2,1,1] => 0 [1,1,3,2,2] => 0 [1,1,3,3,1] => 0 [1,1,3,4] => 0 [1,1,4,1,1,1] => 0 [1,1,4,1,2] => 1 [1,1,4,2,1] => 0 [1,1,4,3] => 0 [1,1,5,1,1] => 0 [1,1,5,2] => 0 [1,1,6,1] => 0 [1,1,7] => 0 [1,2,1,1,1,1,1,1] => 0 [1,2,1,1,1,1,2] => 1 [1,2,1,1,1,2,1] => 1 [1,2,1,1,1,3] => 1 [1,2,1,1,2,1,1] => 1 [1,2,1,1,2,2] => 1 [1,2,1,1,3,1] => 1 [1,2,1,1,4] => 1 [1,2,1,2,1,1,1] => 1 [1,2,1,2,1,2] => 2 [1,2,1,2,2,1] => 1 [1,2,1,2,3] => 1 [1,2,1,3,1,1] => 1 [1,2,1,3,2] => 1 [1,2,1,4,1] => 1 [1,2,1,5] => 1 [1,2,2,1,1,1,1] => 0 [1,2,2,1,1,2] => 1 [1,2,2,1,2,1] => 1 [1,2,2,1,3] => 1 [1,2,2,2,1,1] => 0 [1,2,2,2,2] => 0 [1,2,2,3,1] => 0 [1,2,2,4] => 0 [1,2,3,1,1,1] => 0 [1,2,3,1,2] => 1 [1,2,3,2,1] => 0 [1,2,3,3] => 0 [1,2,4,1,1] => 0 [1,2,4,2] => 0 [1,2,5,1] => 0 [1,2,6] => 0 [1,3,1,1,1,1,1] => 0 [1,3,1,1,1,2] => 1 [1,3,1,1,2,1] => 1 [1,3,1,1,3] => 1 [1,3,1,2,1,1] => 1 [1,3,1,2,2] => 1 [1,3,1,3,1] => 1 [1,3,1,4] => 1 [1,3,2,1,1,1] => 0 [1,3,2,1,2] => 1 [1,3,2,2,1] => 0 [1,3,2,3] => 2 [1,3,3,1,1] => 0 [1,3,3,2] => 0 [1,3,4,1] => 0 [1,3,5] => 0 [1,4,1,1,1,1] => 0 [1,4,1,1,2] => 1 [1,4,1,2,1] => 1 [1,4,1,3] => 1 [1,4,2,1,1] => 0 [1,4,2,2] => 0 [1,4,3,1] => 0 [1,4,4] => 0 [1,5,1,1,1] => 0 [1,5,1,2] => 1 [1,5,2,1] => 0 [1,5,3] => 0 [1,6,1,1] => 0 [1,6,2] => 0 [1,7,1] => 0 [1,8] => 0 [2,1,1,1,1,1,1,1] => 0 [2,1,1,1,1,1,2] => 1 [2,1,1,1,1,2,1] => 1 [2,1,1,1,1,3] => 1 [2,1,1,1,2,1,1] => 1 [2,1,1,1,2,2] => 1 [2,1,1,1,3,1] => 1 [2,1,1,1,4] => 1 [2,1,1,2,1,1,1] => 1 [2,1,1,2,1,2] => 2 [2,1,1,2,2,1] => 1 [2,1,1,2,3] => 1 [2,1,1,3,1,1] => 1 [2,1,1,3,2] => 1 [2,1,1,4,1] => 1 [2,1,1,5] => 1 [2,1,2,1,1,1,1] => 1 [2,1,2,1,1,2] => 2 [2,1,2,1,2,1] => 2 [2,1,2,1,3] => 2 [2,1,2,2,1,1] => 1 [2,1,2,2,2] => 1 [2,1,2,3,1] => 1 [2,1,2,4] => 1 [2,1,3,1,1,1] => 1 [2,1,3,1,2] => 2 [2,1,3,2,1] => 1 [2,1,3,3] => 1 [2,1,4,1,1] => 1 [2,1,4,2] => 1 [2,1,5,1] => 1 [2,1,6] => 1 [2,2,1,1,1,1,1] => 0 [2,2,1,1,1,2] => 1 [2,2,1,1,2,1] => 1 [2,2,1,1,3] => 1 [2,2,1,2,1,1] => 1 [2,2,1,2,2] => 1 [2,2,1,3,1] => 1 [2,2,1,4] => 1 [2,2,2,1,1,1] => 0 [2,2,2,1,2] => 1 [2,2,2,2,1] => 0 [2,2,2,3] => 0 [2,2,3,1,1] => 0 [2,2,3,2] => 0 [2,2,4,1] => 0 [2,2,5] => 0 [2,3,1,1,1,1] => 0 [2,3,1,1,2] => 1 [2,3,1,2,1] => 1 [2,3,1,3] => 1 [2,3,2,1,1] => 0 [2,3,2,2] => 0 [2,3,3,1] => 0 [2,3,4] => 0 [2,4,1,1,1] => 0 [2,4,1,2] => 1 [2,4,2,1] => 0 [2,4,3] => 0 [2,5,1,1] => 0 [2,5,2] => 0 [2,6,1] => 0 [2,7] => 0 [3,1,1,1,1,1,1] => 0 [3,1,1,1,1,2] => 1 [3,1,1,1,2,1] => 1 [3,1,1,1,3] => 1 [3,1,1,2,1,1] => 1 [3,1,1,2,2] => 1 [3,1,1,3,1] => 1 [3,1,1,4] => 1 [3,1,2,1,1,1] => 1 [3,1,2,1,2] => 2 [3,1,2,2,1] => 1 [3,1,2,3] => 1 [3,1,3,1,1] => 1 [3,1,3,2] => 1 [3,1,4,1] => 1 [3,1,5] => 1 [3,2,1,1,1,1] => 0 [3,2,1,1,2] => 1 [3,2,1,2,1] => 1 [3,2,1,3] => 1 [3,2,2,1,1] => 0 [3,2,2,2] => 0 [3,2,3,1] => 2 [3,2,4] => 2 [3,3,1,1,1] => 0 [3,3,1,2] => 1 [3,3,2,1] => 0 [3,3,3] => 0 [3,4,1,1] => 0 [3,4,2] => 0 [3,5,1] => 0 [3,6] => 0 [4,1,1,1,1,1] => 0 [4,1,1,1,2] => 1 [4,1,1,2,1] => 1 [4,1,1,3] => 1 [4,1,2,1,1] => 1 [4,1,2,2] => 1 [4,1,3,1] => 1 [4,1,4] => 1 [4,2,1,1,1] => 0 [4,2,1,2] => 1 [4,2,2,1] => 0 [4,2,3] => 2 [4,3,1,1] => 0 [4,3,2] => 0 [4,4,1] => 0 [4,5] => 0 [5,1,1,1,1] => 0 [5,1,1,2] => 1 [5,1,2,1] => 1 [5,1,3] => 1 [5,2,1,1] => 0 [5,2,2] => 0 [5,3,1] => 0 [5,4] => 0 [6,1,1,1] => 0 [6,1,2] => 1 [6,2,1] => 0 [6,3] => 0 [7,1,1] => 0 [7,2] => 0 [8,1] => 0 [9] => 0 [1,1,1,1,1,1,1,1,1,1] => 0 [1,1,1,1,1,1,2,2] => 0 [1,1,1,1,2,1,1,2] => 1 [1,1,1,1,2,2,1,1] => 0 [1,1,1,1,3,3] => 0 [1,1,1,1,5,1] => 0 [1,1,2,1,1,1,1,2] => 1 [1,1,2,1,1,2,1,1] => 1 [1,1,2,1,2,3] => 1 [1,1,2,2,1,1,1,1] => 0 [1,1,2,2,2,2] => 0 [1,1,3,1,1,3] => 1 [1,1,3,2,1,2] => 1 [1,1,3,3,1,1] => 0 [1,1,4,4] => 0 [1,1,7,1] => 0 [1,2,1,1,4,1] => 1 [1,2,6,1] => 0 [1,3,1,1,3,1] => 1 [1,3,5,1] => 0 [1,4,1,1,2,1] => 1 [1,4,4,1] => 0 [1,5,1,1,1,1] => 0 [1,5,3,1] => 0 [1,6,1,2] => 1 [1,6,2,1] => 0 [1,7,1,1] => 0 [1,8,1] => 0 [1,9] => 0 [2,1,1,1,1,1,1,2] => 1 [2,1,1,1,1,2,1,1] => 1 [2,1,1,1,2,3] => 1 [2,1,1,2,1,1,1,1] => 1 [2,1,1,2,2,2] => 1 [2,1,2,1,1,3] => 2 [2,1,2,2,1,2] => 2 [2,1,2,3,1,1] => 1 [2,1,3,4] => 1 [2,1,6,1] => 1 [2,2,1,1,1,1,1,1] => 0 [2,2,1,1,2,2] => 1 [2,2,2,1,1,2] => 1 [2,2,2,2,1,1] => 0 [2,2,3,3] => 0 [3,1,1,1,1,3] => 1 [3,1,1,2,1,2] => 2 [3,1,1,3,1,1] => 1 [3,1,2,4] => 1 [3,2,1,1,1,2] => 1 [3,2,1,2,1,1] => 1 [3,2,2,3] => 2 [3,3,1,1,1,1] => 0 [3,3,2,2] => 0 [4,1,1,4] => 1 [4,2,1,3] => 1 [4,3,1,2] => 1 [4,4,1,1] => 0 [5,5] => 0 [8,1,1] => 0 [9,1] => 0 [1,10] => 0 [1,8,1,1] => 0 [1,7,2,1] => 0 [1,6,3,1] => 0 [1,5,4,1] => 0 [1,4,5,1] => 0 [1,3,6,1] => 0 [1,2,7,1] => 0 [1,1,8,1] => 0 [10,1] => 0 [1,1,1,1,1,1,1,1,1,1,1,1] => 0 [1,1,1,1,1,1,1,1,2,2] => 0 [1,1,1,1,1,1,2,2,1,1] => 0 [1,1,1,1,1,1,2,1,1,2] => 1 [1,1,1,1,1,1,3,3] => 0 [1,1,1,1,2,2,1,1,1,1] => 0 [1,1,1,1,2,2,2,2] => 0 [1,1,1,1,2,1,1,2,1,1] => 1 [1,1,1,1,2,1,1,1,1,2] => 1 [1,1,1,1,2,1,2,3] => 1 [1,1,1,1,3,3,1,1] => 0 [1,1,1,1,3,2,1,2] => 1 [1,1,1,1,3,1,1,3] => 1 [1,1,1,1,4,4] => 0 [1,1,2,2,1,1,1,1,1,1] => 0 [1,1,2,2,1,1,2,2] => 1 [1,1,2,2,2,2,1,1] => 0 [1,1,2,2,2,1,1,2] => 1 [1,1,2,2,3,3] => 0 [1,1,2,1,1,2,1,1,1,1] => 1 [1,1,2,1,1,2,2,2] => 1 [1,1,2,1,1,1,1,2,1,1] => 1 [1,1,2,1,1,1,1,1,1,2] => 1 [1,1,2,1,1,1,2,3] => 1 [1,1,2,1,2,3,1,1] => 1 [1,1,2,1,2,2,1,2] => 2 [1,1,2,1,2,1,1,3] => 2 [1,1,2,1,3,4] => 1 [1,1,3,3,1,1,1,1] => 0 [1,1,3,3,2,2] => 0 [1,1,3,2,1,2,1,1] => 1 [1,1,3,2,1,1,1,2] => 1 [1,1,3,2,2,3] => 2 [1,1,3,1,1,3,1,1] => 1 [1,1,3,1,1,2,1,2] => 2 [1,1,3,1,1,1,1,3] => 1 [1,1,3,1,2,4] => 1 [1,1,4,4,1,1] => 0 [1,1,4,3,1,2] => 1 [1,1,4,2,1,3] => 1 [1,1,4,1,1,4] => 1 [1,1,5,5] => 0 [2,2,1,1,1,1,1,1,1,1] => 0 [2,2,1,1,1,1,2,2] => 1 [2,2,1,1,2,2,1,1] => 1 [2,2,1,1,2,1,1,2] => 2 [2,2,1,1,3,3] => 1 [2,2,2,2,1,1,1,1] => 0 [2,2,2,2,2,2] => 0 [2,2,2,1,1,2,1,1] => 1 [2,2,2,1,1,1,1,2] => 1 [2,2,2,1,2,3] => 1 [2,2,3,3,1,1] => 0 [2,2,3,2,1,2] => 1 [2,2,3,1,1,3] => 1 [2,2,4,4] => 0 [2,1,1,2,1,1,1,1,1,1] => 1 [2,1,1,2,1,1,2,2] => 2 [2,1,1,2,2,2,1,1] => 1 [2,1,1,2,2,1,1,2] => 2 [2,1,1,2,3,3] => 1 [2,1,1,1,1,2,1,1,1,1] => 1 [2,1,1,1,1,2,2,2] => 1 [2,1,1,1,1,1,1,2,1,1] => 1 [2,1,1,1,1,1,1,1,1,2] => 1 [2,1,1,1,1,1,2,3] => 1 [2,1,1,1,2,3,1,1] => 1 [2,1,1,1,2,2,1,2] => 2 [2,1,1,1,2,1,1,3] => 2 [2,1,1,1,3,4] => 1 [2,1,2,3,1,1,1,1] => 1 [2,1,2,3,2,2] => 1 [2,1,2,2,1,2,1,1] => 2 [2,1,2,2,1,1,1,2] => 2 [2,1,2,2,2,3] => 1 [2,1,2,1,1,3,1,1] => 2 [2,1,2,1,1,2,1,2] => 3 [2,1,2,1,1,1,1,3] => 2 [2,1,2,1,2,4] => 2 [2,1,3,4,1,1] => 1 [2,1,3,3,1,2] => 2 [2,1,3,2,1,3] => 2 [2,1,3,1,1,4] => 2 [2,1,4,5] => 1 [3,3,1,1,1,1,1,1] => 0 [3,3,1,1,2,2] => 1 [3,3,2,2,1,1] => 0 [3,3,2,1,1,2] => 1 [3,3,3,3] => 0 [3,2,1,2,1,1,1,1] => 1 [3,2,1,2,2,2] => 1 [3,2,1,1,1,2,1,1] => 1 [3,2,1,1,1,1,1,2] => 1 [3,2,1,1,2,3] => 1 [3,2,2,3,1,1] => 2 [3,2,2,2,1,2] => 1 [3,2,2,1,1,3] => 1 [3,2,3,4] => 2 [3,1,1,3,1,1,1,1] => 1 [3,1,1,3,2,2] => 1 [3,1,1,2,1,2,1,1] => 2 [3,1,1,2,1,1,1,2] => 2 [3,1,1,2,2,3] => 1 [3,1,1,1,1,3,1,1] => 1 [3,1,1,1,1,2,1,2] => 2 [3,1,1,1,1,1,1,3] => 1 [3,1,1,1,2,4] => 1 [3,1,2,4,1,1] => 1 [3,1,2,3,1,2] => 2 [3,1,2,2,1,3] => 2 [3,1,2,1,1,4] => 2 [3,1,3,5] => 1 [4,4,1,1,1,1] => 0 [4,4,2,2] => 0 [4,3,1,2,1,1] => 1 [4,3,1,1,1,2] => 1 [4,3,2,3] => 2 [4,2,1,3,1,1] => 1 [4,2,1,2,1,2] => 2 [4,2,1,1,1,3] => 1 [4,2,2,4] => 2 [4,1,1,4,1,1] => 1 [4,1,1,3,1,2] => 2 [4,1,1,2,1,3] => 2 [4,1,1,1,1,4] => 1 [4,1,2,5] => 1 [5,5,1,1] => 0 [5,4,1,2] => 1 [5,3,1,3] => 1 [5,2,1,4] => 1 [5,1,1,5] => 1 [6,6] => 0 ----------------------------------------------------------------------------- Created: May 18, 2017 at 09:37 by Martin Rubey ----------------------------------------------------------------------------- Last Updated: Jan 11, 2018 at 10:01 by Martin Rubey