well i know for myself i am learning from this website The Java™ Tutorials and the scja and scjp
books and they give u all this code a small explanation on how to code it, then u get to the...
Type: Posts; User: em1980
well i know for myself i am learning from this website The Java™ Tutorials and the scja and scjp
books and they give u all this code a small explanation on how to code it, then u get to the...
ok i figured it out on my own thought it was way more complicated than what it was i madethe display method i just never used it
public class Animals {
public static void main(String args[]){...
this is the code another way
package com.emcher.animal;
public class Animals {
public static void main(String args[]){
Dog dog = new Dog();
dog.setAnimalType("dog");
this is the code
public class Animals {
public static void main(String args[]){
Dog dog = new Dog();
dog.setAnimalType("dog");
Cat cat = new Cat();
cat.setAnimalType("cat");
forget it i will do it on my own u confusing me even more
i figured out how to pass objects into the parameters as shown in the code above i cannot get the method to display the objects on the console i tried putting the displayObject method into the main...
i am doing an exercise in a book and the book is telling me to make 3 objects cat dog and fish then to pass them into into a method. the method must then display the name of each object
this is what i have coded so far
public class Animals {
public static void main(String args[]){
Dog dog = new Dog();
dog.setAnimalType("dog");
Cat cat = new Cat();...