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
Juli2301 [7.4K]
3 years ago
5

Write java code that displays all the objects in a stack in the order in which they were pushed onto it. after all the objects a

re displayed, the stack should have the same contents as when you started. files to be submitted: taskademo.java arraystack.java stackinterface.java
Computers and Technology
1 answer:
kolbaska11 [484]3 years ago
7 0
Let's assume you have a stack called "s".
You can very simply print each element out using a for each loop (the iterable (as shown below), or a classic for each loop, if you prefer). This method does not modify the stack in any way.

s.forEach(System.out::println);
You might be interested in
As a student, how can you sustain focus and attention with technology distracting you from things that matter (academic, persona
ki77a [65]
Technology is addicting and distracting, just take personal experience. Have you ever had a time when you were on the computer, on the phone, playing games, watching TV, etc. and time flew by? You were procrastinating and should have been doing something else? Were you ever multitasking and paid more attention to technology than what you should be doing? If so, then you have your answer, and from your own experience as well.
6 0
2 years ago
Cotización de un software
Mashcka [7]

Answer:

translate it

Explanation:

3 0
3 years ago
The function below takes a single parameter number_list which is a list that can contain integers and floats. Complete the funct
Andreas93 [3]

Answer:

  1. def getLargest(number_list):
  2.    new_list = []
  3.    for x in number_list:
  4.        if(isinstance(x, int)):
  5.            new_list.append(x)
  6.    largest = max(new_list)
  7.    return largest  

Explanation:

Firstly, create a function <em>getLargest()</em> that take one input parameter, <em>number_list</em>.

The function will filter out the float type number from the list by using <em>isinstance() </em>method (Line 5). This method will check if a current x value is an integer. If so, the x value will be added to <em>new_list</em>.

Next, use Python built-in <em>max</em> function to get the largest integer from the <em>new_list </em>and return it as output.

6 0
3 years ago
how do i turn off itallics on a school chromebook i accidentally turned them on in another tab and i dont know how to undo them
Rudiy27
U go in to the bar with i b u the is italics and u press it again and it will turn it off but u have to have the text selected
5 0
2 years ago
What was the strategy the company adopted for ERP implementation?
SashulF [63]

Answer:

Big Bang or Phased Approach – ERP Implementation strategies include Big Bang, Phased, Hybrid, and Parallel Adoption. Each organization requirements are different and as such, the project management method is itself evolving using PPM, SCRUM, and DevOps.

8 0
2 years ago
Other questions:
  • Plz help ASAP
    10·1 answer
  • You can avoid culture shock by ____________.
    10·2 answers
  • The default (preset slide layouts are set up in ____ orientation.
    15·1 answer
  • Vghfthcnbvhghvngjgjvjgkb, kcnjc cnnfjdhd mc Dan Jfhjc cm. Cm n n hdjfjocnkcnd
    10·2 answers
  • The ash and dust from a volcanic eruption can cause a ______ change in the environment.
    8·1 answer
  • ICS facilitates the ability to communicate by using:
    7·1 answer
  • if a second system failure occurs while the first recovery is in progress, what needs tobe done after the system recovers for th
    11·1 answer
  • Write a program to assign and display a string value to any variable of your choice
    10·1 answer
  • You want to send an email to members of your team working on a school project. In which field would you put the email addresses
    13·1 answer
  • Which type of inventory control is expensive but helps keep inventory especially secure? A. RFID tags B. Barcodes C. Visual merc
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!