c++, C/C++ Programming

Assignment Help:
#questAt a shop of marbles, packs of marbles are prepared. Packets are named A, B, C, D, E …….. All packets are kept in a VERTICAL SHELF in random order. Any numbers of packets with these names could be kept in that shelf as in this example: bottom of shelf ---> [AAAJKRDFDEWAAYFYYKK]-----Top of shelf. All these packets are to be loaded on cars. The cars are lined in order, so that the packet could be loaded on them. The cars are also named [A, B, C, D, E,………….]. Each Car will load the packet with the same alphabet. So, for example, car ‘A’ will load all the packets with name ‘A’. Each particular car will come at the loading point only once. The cars will come at the loading point in alphabetical order. So, car ‘B’ will come and take all the packets with name ‘B’ from the shelf, then car ‘C’ will come. No matter how deep in the shelf any packet ‘B’ is, all of the ‘B’ packets will be displaced before the ‘C’ car arrives. For that purpose, some additional shelves are provided. The packets which are after the packet B, are kept in those shelves. Any one of these shelves contains only packets, having the same name. For example, if any particular shelf is used and if a packet with name X is in it, then only the packets having names X will be kept in it. That shelf will look like [XXXXXXX]. If any shelf is used once, then it could be used again only if it is vacant. Packets from the initial shelf could be unloaded from top only. Write a program that finds the minimum total number of shelves, including the initial one required for this loading process. ion..

Related Discussions:- c++

Does improper inheritance have potential to wreck a project, Does improper ...

Does improper inheritance have a potential to wreck a project? Many projects meet a dead end due to bad inheritance. Hence it certainly has potential to wreck a project. Sma

Storing street addresses with doubly linked lists, Write a C++ program with...

Write a C++ program with header and source files to store street addresses using the Doubly Linked List ADT. Modify the Node class from Lab Assignment 3 so that it becomes a node i

Make c code works equally on 64 and 32 bit, Project Description: I have ...

Project Description: I have a code that works different on 64 bit and 32 bit system. Code is relative to some crypt functions, similar, but not equal to: I have to move fr

Define the keywords of c language, Define the Keywords of c language? C...

Define the Keywords of c language? C keeps a small set of keywords for its personal use. These keywords can't be used as identifiers in the program. Here is the list of keyword

Luminous Jewels - The Polishing Game, First line starts with T, number of t...

First line starts with T, number of test cases. Each test case T contains a necklace (N).

Compiler Design - Limit In The Method Instructions, Raj is a newbie to the ...

Raj is a newbie to the programming and while learning the programming language he came to know the following rules: · Each program must start with ''{'' and end with ''}''

Heating and thermodynamic, i want software to calculate heating or use ther...

i want software to calculate heating or use thermodynamic equation , pleas help me

C, algo of stack using two queue

algo of stack using two queue

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd