Author Message

pixi

si
Posts: 113

Location: Slovenia
Occupation: Speed addicted
Age: 31
V$:
#1   2010-05-23 11:03          
public class Zival{
private String ime; //Spremenljivka spol, ki vsebuje podatek katerega spola je zival
private int starost; //Spremenljivka starost, ki predstavlja starost v letih
public Zival () {}//Privzeti konstruktor
public Zival (String i, int st) {//Konstruktor z parametri
ime=i;
starost=st;
}
public String getIme(){//Metoda getIme
return ime;
}
public int getStarost(){//Metoda getStarost
return starost;
}
public void setIme(String i){//Metoda setIme
ime=i;
}
public void setStarost (int st){//Metoda setStarost
starost=st;
}
public String toString() {//Metoda toString
return "Zivali je ime"+ime+"in je stara"+starost;
}
public static void main (String[]args) {//Metoda Main
Zival z1=new Zival( bella ,2);
System.out.println( "Ime:" + z1.getIme());
System.out.println("Starost: " + z1.getStarost());
z1.setIme( floki );
z1.setStarost(7);
System.out.println (z1.toString ());
}
}

this is error report:

C:\Documents and Settings\Shaggx\My Documents\Zival.java:25: cannot find symbol
symbol : variable bella
location: class Zival
Zival z1=new Zival( bella ,2);
^
C:\Documents and Settings\Shaggx\My Documents\Zival.java:28: cannot find symbol
symbol : variable floki
location: class Zival
z1.setIme( floki );
^
2 errors

Tool completed with exit code 1
Basic of speed.
It's not the car it matters, more iportant is to have guts to drive fast AND calm and clear mind to see the limits of YOU, CAR and ROAD