Spreadsheet: 754136d1635957996-counting-cells-in-between-2-values-book1-example
Sheet: Sheet1

# | ##
0 |  |  | Count the number of cells between the '0' values working downwards and display value in the <formula> cell adjacent.
1
0 |  |  | E.g. 1
1
0 |  |  | E.g. 2
1
1
0 |  |  | E.g. 1
1
0 |  |  | E.g. 1
1
0 |  |  | E.g. 2
1
1
0 |  |  | E.g. 2
1
1
0 |  |  | E.g. 1
1
0 |  |  | E.g. 6
1
1
1
1
1
1
0 |  |  | E.g. 2
1
1
0 |  |  | E.g. 1
1
0
1
0
1
1
0
1
0
1
1
1
0
1
1
0
1
1
1
1
0
1
1
1
0
1
1
1
1
1
0
1
0
1
1
0
1
1
0
1
1
1
1
1
1
0
1
1
1
1
1
1
1
0
1
1
0
1
0
1
1
1
1
0
1
0
1
0
1
1
0
1
1
1
0
1
0
1
1
0
1
1
1
1
0
1
1
0
1
1
1
0
1
1
0
1
1
0
1
0
1
0
1
0
1
1
0
1
1
1
1
1
0
1
0
1
1
1
1
1
1
1
1
0
1
0
1
1
1
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
1
1
1
0
1
1
1
1
0
1
0
1
1
0
1
1
1
0
1
0
1
1
0
1
0
1
0
1
1
0
1
1
1
0
1
0
1
0
1
1
1
1
0
1
1
1
1
0
1
0
1
1
0
1
0
1
1
1
0
1
0
1
0
1
1
1
1
1
0
1
0
1
1
0
1
1
1
1
0
1
0
1
1
1
0
1
1
1
1
0
1
0
1
1
0
1
0
1
0
1
0
1
0
1
0
1
1
0
1
1
1
0
1
0
1
1
0
1
0
1
0
1
1
0
1
0
1
1
0
1
0
1
1
1
1
1
1
1
0
1
1
0
1
0
1
1
1
0
1
0
1
1
0
1
0
1
0
1
0
1
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
0
1
1
1
1
0
1
1
1
1
1
0
1
0
1
0
1
0
1
0
1
1
1
0
1
1
1
0
1
1
1
1
0
1
0
1
1
0
1
0
1
1
0
1
0
1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