Share your repls and programming experiences

← Back to all posts
uhhh
LiamRobins (0)

/
public class Store
{
private String location = "1 Bass Pro Drive, Memphis, Tennessee";
private Item[] baselist = new Item[3];
Item rod;
/

baselist[0] = rod;
baselist[1] = new Item("Fishing hat", "a hat which says, 'WOMEN LOVE ME; FISH FEAR ME'", .5, 5);
baselist[2] = new Item("Fishhooks", "a box of 50 hooks used for fishing", 1.5, 6);

private Item[] itemlist = baselist;
private String owner = "Johny Morris";
private String phonenumber = "(901) 291-8200";
public Store()
{
rod = new Item("Fishing rod", "a rod used to catch fish", 10, 30);
}
public Store(String l, Item[] i, String o, String p)
{
location = l;
itemlist = i;
owner = o;
phonenumber = p;
}
}
*/