static int[]
	offsets(final ISeq<? extends FlatTree<? extends Op<?>, ?>> nodes) {
		final int[] offsets = new int[nodes.size()];

		int offset = 1;
		for (int i = 0; i < offsets.length; ++i) {
			final Op<?> op = nodes.get(i).value();

			offsets[i] = op.isTerminal() ? -1 : offset;
			offset += op.arity();
		}

		return offsets;
	}
Create the offset array for the given nodes. The offsets are calculated
using the arity of the stored operations.

@param nodes the flattened tree nodes
@return the offset array for the given nodes
jenetics.prog/src/main/java/io/jenetics/prog/op/Program.java