!7 p { RGBImage rgb = loadImage(#1006358); int w = rgb.w(), h = rgb.h(); *float[h] data; for y to h: data[y] = rangeLength(printStruct(wideBlack(rgb, w/2, y))); showImageWithVerticalGraph(rgb, data); } static Range wideBlack(RGBImage img, int x, int y) { int w = img.w(); int x1 = x, x2 = x; while (x1 > 0 && img.getPixel(x1-1, y).getBrightness() < 0.1) --x1; while (x2 < w && img.getPixel(x2, y).getBrightness() < 0.1) ++x2; ret new Range(x1, x2); }