Guest User

Node

a guest
Apr 4th, 2016
153
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.59 KB | None | 0 0
  1. public class Node {
  2. int nrWiersza=0;
  3. int nrKolumny=0;
  4. int WartoscElementu;
  5. Node nextKolumna;
  6. Node nextWiersz;
  7.  
  8. public Node(int WartoscElementu){
  9. this.WartoscElementu = WartoscElementu;
  10. }
  11.  
  12. public int getNrWiersza(){
  13. return nrWiersza;
  14. }
  15. public int getNrKolumny(){
  16. return nrKolumny;
  17. }
  18. public int getWarElem(){
  19. return WartoscElementu;
  20. }
  21. public String toString(){
  22. return "Numer Wiersza: " + nrWiersza + "\nNumer Kolumny: " + nrKolumny + "\nWartosc Elementu: " + WartoscElementu;
  23. }
  24. public void display(){
  25. System.out.println(WartoscElementu);
  26.  
  27. }
  28.  
  29. }
Add Comment
Please, Sign In to add comment