PEX5

Download Category:

PEX5.zip - (470.16 KB)
[
PEX5/Debug/
PEX5/Debug/cl.command.1.tlog
PEX5/Debug/CL.read.1.tlog
PEX5/Debug/CL.write.1.tlog
PEX5/Debug/link.1948.read.1.tlog
PEX5/Debug/link.1948.write.1.tlog
PEX5/Debug/link.1948-cvtres.read.1.tlog
PEX5/Debug/link.1948-cvtres.write.1.tlog
PEX5/Debug/link.command.1.tlog
PEX5/Debug/link.read.1.tlog
PEX5/Debug/link.write.1.tlog
PEX5/Debug/link-cvtres.read.1.tlog
PEX5/Debug/link-cvtres.write.1.tlog
PEX5/Debug/mt.command.1.tlog
PEX5/Debug/mt.read.1.tlog
PEX5/Debug/mt.write.1.tlog
PEX5/Debug/PEX5.exe
PEX5/Debug/PEX5.exe.embed.manifest
PEX5/Debug/PEX5.exe.embed.manifest.res
PEX5/Debug/PEX5.exe.intermediate.manifest
PEX5/Debug/PEX5.ilk
PEX5/Debug/PEX5.lastbuildstate
PEX5/Debug/PEX5.log
PEX5/Debug/PEX5.obj
PEX5/Debug/PEX5.pdb
PEX5/Debug/PEX5.write.1.tlog
PEX5/Debug/PEX5_manifest.rc
PEX5/Debug/rc.command.1.tlog
PEX5/Debug/rc.read.1.tlog
PEX5/Debug/rc.write.1.tlog
PEX5/Debug/vc100.idb
PEX5/Debug/vc100.pdb
PEX5/PEX5.cpp
PEX5/PEX5.sln
PEX5/PEX5.suo
PEX5/PEX5.vcxproj
PEX5/PEX5.vcxproj.filters
PEX5/PEX5.vcxproj.user
PEX5/Question.txt
PEX5/Screenshot_1.png
]

Write a C++ program PEX5.cpp that reads a sequence of 20 integers, pushing all of
the even integers onto one stack and all the odd integers onto the other. Output the
contents of each stack by popping elements until its empty. Remember to use the STL
.
THIS IS THE OUTPUT:
Run:
Enter 20 integers:
5 13 25 16 2 4 5 17 457 88 1 9 26 55 100
75 36 8 10 35
Even integers in reverse order:
10 8 36 100 26 88 4 2 16
Odd integers in reverse order:
35 75 55 9 1 457 17 5 25 13 5

Write a Review

Get a fresh solution of this question. Ask it now to our experts.
doubt

Ask Your Question

We have verified professionals who are ready to answer your question.

time

Save Time and Money

We choose experts who can quickly answer your question and that suit your budget.

download

Get Your Answer

Your satisfaction is 100% guaranteed. You can keep on asking questions until you get the answer you need.