"Try the random between 110 and 222:
text will exceed the ellipse"
I was going to try get fancy with it so I can say:
if (MIN>60){
fill(0);
} else{
fill(255);
}
But putting that in the draw function doesn’t seem to be working. Maybe I’m just framing it long.
I’m just trying to get a sense of how to express these sorts of terms even just reading your outline there gives me the right words to google and helps the syntax understanding a lot. Thanks again.
int a[]= new int [50];
int MIN= 255;
void setup()
{
size(450, 450);
for (int i=0; i < a.length; i++)
{
a[i] = (int) random (255);
print(a[i]+" , ");
// println("MIN+", MIN);
}
//MIN = getArrayMin();
if (MIN>60){
fill(0);
} else{
fill(255);
}
}
void draw() {
fill (MIN);
textSize(width/4);
ellipse(width/2, height/2, width/2, height/2);
fill (240);
textSize(width/4);
text(MIN, width*.28, height*.58);
}
int getArrayMin() {
int MIN_local=11000;
for (int i=0; i<a.length; i++)
{
if (a[i]< MIN_local) {
MIN_local= a[i] ;
}
}
return MIN_local;
}