建立m文件draw_rectangle.m. 其中p生成矩形的个数 function draw_rectangle(p) t = 1; x = rand(1)*10; y = rand(1)*10; w = rand(1)*10; h = rand(1)*10; b =[x y w h]; rectangle('Position', b) a{t} =b; flag =1; while flag ==1 x = rand(1)*10; y = rand(1)*10; w = rand(1)*10
Given a list of non-overlapping axis-aligned rectangles rects, write a function pick which randomly and uniformily picks an integer point in the space covered by the rectangles. Note: An integer point is a point that has integer coordinates. A point