Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int radius = 500;
- if (radius > 0)
- {
- for(x=(radius*-1); x<radius; x++)
- {
- for(y=(radius*-1);y<radius;y++)
- {
- if((x*x + y*y) < radius*radius && (x*x + y*y > (radius-1*(radius-1))))
- pixel.setcolor(red);
- else
- pixel.setcolor(blue);
- }
- }
- }
- else
- print("Error: radius must be positive");
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement