//ever piece of code you write in Java will always be included in a class
public class main{
//this piece of code is know as your instance method.
//these are said to be at class level because you need
//to instantiate the class to access them. Here, you will
//need a public constructor and / or public method to perform
//operations on it.
private int intFeild;
{
//inside these brackets represent an initializer
//this is executed on startup
//you can place code inside initializers
}
//below represents a class method. It is used to manipulate or
//retrieve the instance variables declared at class level
public int getIntField(){
return intField;
}
public void setIntFeild(int intField){
this.intField = intField;
}
public static void main(String[] args){
//you sent this code to me only containig colored lines below
//along with line 1, any logic should be included within methods or static initializers
//I cannot determine the format you are implementing here, but it is not considered as
//proper Java syntax from my understanding. Here your local variable are not proper
//declared and initialized (assigned). When within methods, you should get into the
//practice of assigning values (initializing) to your local variables.
//the line directly below is not a Java statement and results in compilation errors
size (1000,1000);
float x= 20;
float y = 20;
for (int column=0; column<5; column++) {
y=y+0;
for (int i=0; i<5; i++){
//line has not been initialized, therefore this code results in compilation errors
line(x,y,x+40,y);
//ellipse has not been initialized, therefore this code results in compilation errors
ellipse(x,y,x-10,y-10);
ellipse(x+35,y+0.95,x-10,y-10);
x=x+0;
}
}
}
}
//please go back and reevaluate the code according to my statements and resend me the updates
//of your progress and I'll review over your changes