Create a stack in c++ for double numbers called xStack


1. Design a stack for double numbers called xStack, which, besides push, pop, isEmpty, peek methods, it has methods for returning the minimum element (min) and the maximum element (max), which should operate in O(1) time, meaning you can't obtain the minimum/maximum by traversing any stack array. xStack should be built using the template class Stack uploaded .

2. Finding the path to the room using the Stack data structure.

A building is represented though a N*M binary matrix of blocks (representing corridors/ stairs, walls and doors). A person, positioned initially at coordinates (0,0) in the building matrix wants to find the door to his room , which has a numerical code (other than 0 and 1): e.g. 101. In the building matrix, we can have 3 types of values: room codes, 0 - means corridors/ stairs, 1 - means walls. A person can go through corridors and stairs till his room . The person can move in any direction (not diagonally) to any matrix block provided the block is not a dead end (walls and doors different from the one he/she is looking for). The task is to check if any path exists so that the person can reach the room and print the path, using the stack data structure.

The input will be 3 building matrices and the code of person's room: the first 2 letters represent the building and the other 3 represent the numerical code inside the building, e.g. MT101.

Example of building matrix for MT building:

MTbuilding[4][5] = {

{0, 104, 0, 0, 1},

{0, 0, 0, 1, 0},

{1, 0, 1, 101, 102},

{0, 0, 0, 0, 0}


Example of output, when the person searches for MT101:

Path Found!

The path can be: (0, 0) -> (1, 0) -> (1, 1) -> (2, 1) -> (3, 1) -> (3, 2) -> (3, 3) -> (2, 3)

3. We want to stock all the available rooms in the campus. The rooms are stocked in a priority queue. Implement a template class called PriorityQueue using the xStack class: the rooms are added to the queue in the classical way, at the end of the queue, but when deleting them, the room which is the closest to the building entrance door is selected. In order to calculate the distance between a room and the building entrance door, the distance formula between 2 points is used. The building entrance door has coordinates (0,0). The room doors have coordinates equal to the line and the column in the matrix building.

We need the source files (.cpp and .h) .

A README file in which you will specify all the functional sections of the project, together with instructions for the user; We need a description with every code line of what it does.

Thank you !

Beceriler: C Programlama, C# Programlama, C++ Programlama, Java, Verilog / VHDL

Daha fazlasını gör: create search database business phone numbers, can create digit random numbers, create prev next page numbers frontpage, double stack in data structure, c++ stack push pop example, stack template c++, stack implementation in c++, stack using linked list c++, stack data structure, push and pop operation in stack in data structure, write a c++ program for stack using template, c++programming, create double linked lists java, create database phone numbers, create flyers tear away numbers, create stack book photoshop, create macro clean phone numbers, create stack images photoshop, create iphone app regular computerbasically called irecommendthisbook comdownload enter email address database downloaded enter , create text message response numbers

İşveren Hakkında:
( 0 değerlendirme ) Craiova, Romania

Proje NO: #19038972



Hello. The first part (O(1) min/max) can be done by either caching min and max values after every push/pop or by maintaining a secondary internal ordering (which can also be used for the third task's priority queue). T Daha Fazla

1 gün içinde %selectedBids___i_sum_sub_4%%project_currencyDetails_sign_sub_5% USD
(27 Değerlendirme)

Bu iş için 9 freelancer ortalamada $49 teklif veriyor

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% USD
(411 Değerlendirme)

Hello, I have 25 years experience programming in C++. I will complete these 3 exercises. A milestone payment for the full budget for this project must be deposited with this site before your offer can be accepte Daha Fazla

$137 USD in 3 gün içinde
(70 Değerlendirme)

Dear sir I have completed projects similar to your requirement in the past. If you could share your project detail requirements, I will share relevant past work and demo. I already developed 100+ windows applicatio Daha Fazla

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% USD
(0 Değerlendirme)

Dear Client, I am highly experienced with C++ development. I have experienc with many projects. Kindly contact me. Thanks

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% USD
(0 Değerlendirme)
$25 USD in 15 gün içinde
(0 Değerlendirme)

Total 18+ years of experience and relevant 9+ years of experience. Expert in data structures, C. worked in embedded domain using C and C++. Created unicode editor for different languages. Have experience in STL usage Daha Fazla

$35 USD in 4 gün içinde
(0 Değerlendirme)

Hi I have over 4 years of experience in programming. I can do ooad projects with the data structures and database. Send me your requirements and i will provide quality work on time. Regards Fahad Hassan

1 gün içinde %bids___i_sum_sub_32%%project_currencyDetails_sign_sub_33% USD
(0 Değerlendirme)
$20 USD in 2 gün içinde
(0 Değerlendirme)