RosettaCodeData/Task/Grayscale-image/Ada/grayscale-image-3.adb
2026-04-30 12:34:36 -04:00

10 lines
308 B
Ada

function Color (Picture : Grayscale_Image) return Image is
Result : Image (Picture'Range (1), Picture'Range (2));
begin
for I in Picture'Range (1) loop
for J in Picture'Range (2) loop
Result (I, J) := (others => Picture (I, J));
end loop;
end loop;
return Result;
end Color;