how to impliment 2 or more stacks in a single dimensional
array ?
Answer Posted / sakthigurunathan
to implement two stacks in a single array consider two
stacks growing towards each other and take tos1=-1
andtos2=max as empty condition and for full condition take
tos1=tos2-1 and to insert take push1 tos1++
and for push2 tos--
Is This Answer Correct ? | 36 Yes | 9 No |
Post New Answer View All Answers
How can you increase the size of a statically allocated array?
What is a good way to implement complex numbers in c?
What are the differences between new and malloc in C?
Want to know how to write a C program that connects to a MySQL server and checks if the InnoDB plug-in is installed on it. If so, your program should print the total number of disk writes by MySQL.
Write an algorithm for implementing insertion and deletion operations in a singly linked list using arrays ?
What is sorting in c plus plus?
What is null pointer constant?
1234554321 1234 4321 123 321 12 21 1 1 12 21 123 321 1234 4321 1234554321
What are logical errors and how does it differ from syntax errors?
write a program to convert a expression in polish notation(postfix) to inline(normal) something like make 723+* (2+3) x 7 (not sure) just check out its mainly printing expression in postfix form to infix.
Describe dynamic data structure in c programming language?
Explain what will the preprocessor do for a program?
Write a program to show the change in position of a cursor using c
what is different between auto and local static? why should we use local static?
How can I open files mentioned on the command line, and parse option flags?