Results 1 to 2 of 2
Thread: CIrcular Arrays
- 03-24-2011, 09:24 PM #1
Senior Member
- Join Date
- Oct 2010
- Location
- Newark,nj
- Posts
- 111
- Rep Power
- 0
CIrcular Arrays
Suppose a classed name undostack implements a stack that allows unlimited pushes by forgetting old data as described above by using a circular arry.the data is stored inj a private array memeber declared as Object data[]. Private data meber B is the index of the bottom element in the stack. Member T is the top of the stack.Member C is the count of how many objects are in the stack.......
i wrote the constructor as
I WANTED TO ASK CAN ANYONE GUIDE ME TO HOW I WRITE A BASIC PUSH AND POP METHOD??Java Code:public UndoStack(initialSize){ //constructor data = new Object[initialSize]; t=0; b=data.length-1; c=0
- 03-25-2011, 07:30 AM #2
Senior Member
- Join Date
- Jun 2008
- Posts
- 2,366
- Rep Power
- 7
Similar Threads
-
Trouble with circular singly linked queue
By somewierdguy in forum New To JavaReplies: 2Last Post: 12-06-2010, 01:48 AM -
Need help with circular arrays
By bap2 in forum New To JavaReplies: 6Last Post: 11-04-2010, 08:39 PM -
Problem prioritizing a circular queue
By Metastar in forum New To JavaReplies: 1Last Post: 10-03-2010, 11:40 PM -
Circular Double Linked List
By theonly in forum Advanced JavaReplies: 3Last Post: 12-06-2009, 05:10 PM -
Trouble Developing Singly Linked Circular List
By VinceGuad in forum New To JavaReplies: 14Last Post: 02-25-2009, 04:38 PM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks