1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
muminat
3 years ago
7

Explain how to implement two stacks in one array A[1..n] in such a way that neither stack overflows unless the total number elem

ents in both stacks together exceeds n. Show your work for the new PUSH,POP operations
Computers and Technology
1 answer:
algol [13]3 years ago
5 0

Answer:

Check explanation

Explanation:

Two stacks can make use of one array by utilizing various stack pointers that begins from different ends of an array. Looking at the array A[1...n], the first stack will drive elements that starts from position 1 as well as to move its' pointer to n.

The Second stack will begin at the n position and motion its' pointer to 1. The best likely divide is to offer each stack a half of an array. whenever any of two stacks transverse the half-point, an overflow can happen but for that overall number of elements, it must be n

You might be interested in
Which output will be displayed by the following program?
wolverine [178]

Answer:

h

Explanation:

5 0
3 years ago
Read 2 more answers
dentify the type of observational study​ (cross-sectional, retrospective, or​ prospective) described below. A research company u
valentinak56 [21]

Answer:

A cross-sectional study  

Explanation:

Cross-sectional research in psychology is defined as using a variety of people who differ in the variable of interest but carries other characteristics as well, including educational background, ethnicity, socioeconomic status, etc. It is often used by a researcher who studies developmental psychology. it is used for population-based surveys and to assess the prevalence of disease. These studies are usually inexpensive and relatively faster.

5 0
3 years ago
Python program: Develop a program that will keep track of inventory for a local retail store. Fortunately, the store only offers
EastWind [94]
333 Sweater 500 The better programs will only process data
7 0
3 years ago
Read 2 more answers
An elevator of mass 250kg is carrying two persons whose masses are 50kg and 100kg. if the force exerted by the motor is 3000N. C
Agata [3.3K]

m_{elevator}=250kg \\m_{people}=50kg+100kg=150kg \\m_{motor}\approx3000N\div10\frac{m}{s^2}\approx300kg \\m_{total}\approx250kg+150kg+300kg\approx\boxed{700kg}

Hope this helps.

r3t40

5 0
3 years ago
13) When developing film, how do you dispose of fixer as opposed to developer?
MAVERICK [17]

Answer:

B) Developer is poured down the drain while fixer can be reduced

Explanation:

The effluents produced during photographic processing includes, wash water, bleach, fixer, and developer

The developer is an alkaline solution, with a pH of approximately 10.0, while the pH of the fixer is about 4.3, it is therefore, acidic

The rate of discharge of the developer to the fixer is 2 to 1, and the exhausted developer, fixer and process effluents combined are neutral and can be handle by the the treatment works and the drain pipes

Fixer which remain clear can be reused for more than a day, while the spent basic Developer and the acidic Spent Stop Bath can be combined to form a neutral solution, having a pH of approximately 7, which make them less hazardous to be disposed off down the sink into the drain

Therefore, <em>developer is poured down the drain while fixer can be reused</em>

6 0
3 years ago
Other questions:
  • You just turned on a four port Ethernet switch (it hasn’t learned any addresses yet) and connected a host to each port. You send
    8·1 answer
  • If an attacker decides to implement a less obvious port-scan, or stealth attack, which of the following techniques would be appr
    14·1 answer
  • What kind of energy transformation occurs in a gasoline-powered car?
    14·1 answer
  • List and describe the tools for all the main stages of app/application development.
    11·1 answer
  • Mary feels confident managing Google Search campaigns and is interested in extending her marketing reach with the help of Google
    10·1 answer
  • Which page in a web site do viewers usually see first?
    15·1 answer
  • Write a function called prod_all that takes any number of arguments and returns their sum. Test the function by using these two
    10·1 answer
  • Which wireless standard runs on both the 2.4 and 5 GHz frequencies?
    11·1 answer
  • Once you select a theme, you__________ change the theme’s individual elements independently of each other.
    12·1 answer
  • The first time that a particular visitor loads a web site page is called a(n) _____.
    8·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!