please excuse my noob, but my current level of java knowledge is quite base. I really need help with an exercise, but it is a little beyond my very basic level of Java, (i.e. I'm only confident in declaring variables lol) But here is the question word for word:
Complete a main method that will accomplish the following:
you may assume that the class includes all appropriate set methods(also know as mutator methods) and get methods (also known as accessor methods). The output can be completed using the console output or GUI output.
create a blue kitchen table with 4 legs
create a brown dining table with 6 legs
change the color of the kitchen table to pink
print out the color of the dining table including text identifying which value you are printing and also the value itself.
print out the number of tables including text identifying which value you are print and also the value its self."
So for the last two I need a
System.out.print("the color of the dining table is " + 'diningtable color')
and a
System.out.print("number of tables: " + 'numberOftables');
what's the rest? I really would appreciate help and I know that I need to practice ;)
EDIT
here is what I have now, not sure if my print line is correct:
public static void main (String[] args){
//table 1
table kitchenTable = new table();
kitchenTable.setnumberOfLegs((int)4);
kitchenTable.setcolor("blue");
//table 2
table DiningTable =new table();
DiningTable.setnumberOfLegs((int)6);
DiningTable.setcolor("brown");
//change table 1 to pink
kitchenTable.setcolor("pink");
System.out.print("Dining Table Color is: " + kitchenTable.color());
}