A stack is a last in, first out (LIFO) abstract data type and data structure. Perhaps the most common use of stacks is to store subroutine arguments and return addresses.
0
votes
0answers
6 views
bandwidth monitoring with MRTG, no dat from switch stacks
I'm trying to set up a monitoring system and have been asked to add all of our uplinks in it. most of our switches consists of stacks of about 7 switches. These stacks aren't returning any data.
I ...
0
votes
4answers
29 views
Is it possible to write an _alloca-like function in C?
The function _alloca (alloca) allocates memory on the stack, which does not require "free".
Is it possible to write a function that allocates on the stack in C?
Another way of phrasing it: _alloca ...
1
vote
1answer
27 views
Throwing elements of a node list on stack
I'm using Java and I have a list of nodes, which I need on a Stack in the order from last to first, using List.
Example:
my list is {node1,node2,node3}
my stack is supposed to be
{
node1,
node2,
...
0
votes
1answer
25 views
Stacking z-index issues using :before
For a live demo I've setup the fiddle here
http://jsfiddle.net/OwenMelbz/3PQHa/
Basically I'm trying to create a stack of 2 "photos" - Using purely CSS, cant touch the markup at the moment, but Its ...
1
vote
3answers
79 views
Using STL's list object for Stack creation
I want to create a list of stacks in C++ but the compiler gives me some error messages:
#include <list>
#include <stack>
class cName
{
[...]
...
1
vote
4answers
77 views
Declare large array on Stack
I am using Dev C++ to write a simulation program. For it, I need to declare a single dimensional array with the data type double. It contains 4200000 elements - like double n[4200000].
The compiler ...
0
votes
1answer
29 views
Implementing Queue With Two Stacks - Dequeuing Test Issue?
I'm trying to implement a queue with two stacks for purposes of understanding both data structures a little better. I have the below, with the main function serving as a test:
#include ...
-1
votes
0answers
17 views
Run-Time Check Failure #2 - Stack around the variable was corrupted
I have the following piece of code:
do {
charDeviceName[100]=NULL;
Robot.push_back(Device());
WideCharToMultiByte(CP_ACP,0,m_device_info.szName,-1, charDeviceName,100,&DefChar, ...
0
votes
0answers
16 views
Each image in image stack has an opacity percentage as a fraction of total images
I'm building my own modal (lightbox, pop up) for an image gallery — similar I guess to Fancybox, for example.
I have a page of images, each image represents a specific work or project — if you click ...
1
vote
1answer
50 views
How can I compare entries in linked lists?
I am doing a C project that manages the number of rooms in a building, where I can either choose to reserve or pre-reserve a room. For that, I will ask the user to input some data (name, the ammount ...
0
votes
2answers
61 views
Design a stack with operations on middle element
How to implement a stack which will support following operations in O(1) time complexity?
Push which adds an element to the top of stack.
Pop which removes an element from top of stack.
Find Middle ...
0
votes
2answers
70 views
Variables on heap and stack
I've been trying to look for the answer to this question, but its a little tricky to me.
So it goes!
int square(int* a){
return (*a)*(*a)
}
int main(){
int b = 20;
...
4
votes
2answers
62 views
Is there a bug in java.util.Stack's Iterator?
Today I was trying to push in util.Stack class and then use the Iterator to iterate(without using pop) through the items. I was expecting LIFO property but got surprised.
Here is the code that I was ...
0
votes
0answers
6 views
JQPLOT Bar chart - anyone able to get a bar filled with a pattern?
Playing around with JQPLOT (http://www.jqplot.com/index.php). Creating a stacked bar chart and don't see an option to fill in the bar with some kind of pattern like these -> ...
3
votes
2answers
56 views
Error: deque iterator not dereferenceable
I'm trying to create a program that converts an arithmetic expression from infix to postfix form. As long as I don't call the "infixToPostFix" function, the program runs fine.
But when I try to run ...