Can anyone tell me where I am going wrong with my code? I keep getting two errors stating ';' expected (on lines 22 & 23). I am new to this so I am not sure what I can post and what I can't, so I am just going to post my code and you can tell me different. Thank you.
// Cars.java
//Car inventory program
public class Cars
{
private int itemNumber; // item number
private String itemName; // item name
private int itemTotal; // total of cars in stock
private double itemPrice; // price per car
private double totalInventory; // amount of cars in inventory
// initialize constructor with four arguments
public Cars( int number, String name, int total, double price )
{
itemNumber = number;
itemName = name;
setItemTotal = total of cars;
setItemPrice = price per car;
} // end of constructor with four arguments
public void setItemNumber(int number);
{
itemNumber = number;
}
public int getItemNumber();
{
return itemNumber;
}
public void setItemName(string name);
{
itemName = name;
}
public String getItemName();
{
return itemName;
}
public void setItemTotal(int total);
{
itemTotal = ( total = 9 );
}
public int getItemTotal()
{
return itemTotal;
}
public void setItemPrice (double price)
{
itemPrice = (price = 26738.0);
}
public double getItemPrice()
{
return itemPrice;
}
public double getValue()
{
return itemTotal * itemPrice;
}
}// end class Cars
public class Cars
{
public static void main (String args[])
{
//main method begins execution of java Car application
Cars item = new Cars(
47036, " Toyota Camry" , 9, 26738);
//get car details
System.out.println( " Car Inventory Program" );
System.out.printf( "%s %d\n" , "Item Number: " ,
item.getItemNumber() );
System.out.printf( " %s %s\n" , " Item Name: " ,
product.get.ItemName() );
System.out.printf( " %s %d\n" , " Total items in stock: " ,
product.getItemsTotal() );
System.out.printf( " %s $%g\n" , " Price per item: " ,
product.getItemPrice() );
}// end main method
}// end class Cars