iterat=100;n=200;
x1=-1.5;x2=1.5;
y1=-1.5;y2=1.5;
deltax=(x2-x1)/n;
deltay=(y2-y1)/n;
f[z_]:=z^2+c;
t=Table[{k=0;z=0;c=x + I y;
   While[k<iterat,{z=f[z];erg=Abs[z];If[erg>5,k=iterat,k++]}];
   If[erg>2,n,{x,y}]}[[1]],
   {x,x1,x2,deltax},{y,y1,y2,deltay}
];
tt=Cases[Flatten[t,1],{_,_}];
bild=ListPlot[tt,ImageSize->{400,300}];