Write pseudo code for push in a stack?
Answers were Sorted based on User's Feedback
Answer / sanjeevkumar.v
push it mean INSERT the element to the STACK
| Is This Answer Correct ? | 10 Yes | 14 No |
push means inserting an element on to the top of the stack.
lets define array of size 10,
int a[10]
Top<== -1 // stack is empty now.
Push(x)// x is a element to be push.lets take x=4
{
top<== top+1
// top will initialize to 1,now the top will be address to the 0 th index of array.//
a[Top]<== x
// insert x in to the 0th index of array(a[0]<== 4)//
}
| Is This Answer Correct ? | 0 Yes | 4 No |
i^=j; j^=i; i^=j; value of i,j
Petrol pump mgt. system: To design a program that display an interface for the sale of the Petrol and then make the entries at the backend in the database.
what is the difference between containership and inheritence?
What is difference between oop and pop?
what is cast operator?
What is a null tree?
Write a program to sort the number with different sorts in one program ??
What is class encapsulation?
What are the types of abstraction?
Write a program to reverse a string using recursive function?
What is difference between abstraction and encapsulation?
What is multilevel inheritance in oop?