Java Stack programming
•
17 Apr 2013, 17:38
•
Journals
sup cf,
Have a task due tomorrow:
programming a simple stack in Java and reading data out of that stack.
we have to put 4 Strings into 1 object (a person) + read it.
after that we have to read the ID of the person and tell wich group ID he has (use of a help stack ??).
anyways we are stuck.
if you want to help 2 newb java students plz PM me.
Have a task due tomorrow:
programming a simple stack in Java and reading data out of that stack.
we have to put 4 Strings into 1 object (a person) + read it.
after that we have to read the ID of the person and tell wich group ID he has (use of a help stack ??).
anyways we are stuck.
if you want to help 2 newb java students plz PM me.
and my 1 billion pages book
}
A stack is a pile of objects(not Java objects), the first thing you add to the stack is the last thing you can get out. Starting from there you can do whatever you need with it.
Anyway, look here: http://algs4.cs.princeton.edu/13stacks/Stack.java.html
You MUST put the "Push" "Pop" and "Create Stack" from there into your project.
P.S: Java sucks
P.S2: You are welcome