subject

Write a function that takes a string parameter and determines whether the string contains matching grouping symbols. Grouping symbols are parenthesis ( ) , brackets [] and curly braces { }. For example, the string {a(b+ac)d[xy]g} and kab*cd contain matching grouping symbols. However, the strings ac)cd(e(k, xy{za(dx)k, and {a(b+ac}d) do not contain matching grouping symbols. (Note: open and closed grouping symbols have to match both in number and in the order they occur in the string). Your function must use a stack data structure to determine whether the string parameter satisfies the condition described above. You may define your own stack class or use the STL stack class. Write a driver program (i. e. a function main()) to test your function. Deliverables: 1. a copy of your function and the test driver program source codes in a text file (e. g. a .cpp file) 2. screen shots of your test driver program runs showing it meets the problem's specifications.

ansver
Answers: 2

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 08:00
Someone with this coz i don’t really know what i can choose, just pick whatever u want. homework - you need to choose a website that you like or use frequently. you must visit the website and discuss 6 different features/parts/aspects of the website that you think makes it good. (100 words)
Answers: 2
question
Computers and Technology, 22.06.2019 12:30
An atom's diameter is about 0.1 nanometer (1×10-9m), and a human hair is about 1×10-3m. how many times greater is a human hair than an atom's diameter? sorry pushed wronf button but this is math
Answers: 3
question
Computers and Technology, 22.06.2019 14:00
Which database model is best used for data warehouse and data mining
Answers: 3
question
Computers and Technology, 22.06.2019 18:30
All of the following are characteristics that must be contained in any knowledge representation scheme except
Answers: 3
You know the right answer?
Write a function that takes a string parameter and determines whether the string contains matching g...
Questions
question
Mathematics, 23.06.2021 22:20
question
Mathematics, 23.06.2021 22:20
question
Mathematics, 23.06.2021 22:20
question
Mathematics, 23.06.2021 22:30
question
Mathematics, 23.06.2021 22:30
question
Mathematics, 23.06.2021 22:30
Questions on the website: 13722361