c++, Computer Engineering

Assignment Help:
At 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.

Related Discussions:- c++

What is elapsed time of computer system, What is elapsed time of computer s...

What is elapsed time of computer system? The total time to implement the total program is known as elapsed time. It is affected by the speed of the processor, the disk and the

Explain parsing, What is parsing? The target of parsing is to find out...

What is parsing? The target of parsing is to find out the syntactic validity of a source string. A tree is built for use through subsequent phase of compiler, if the string is

Explain use of parallel sections construct, Q. Explain use of parallel sect...

Q. Explain use of parallel sections construct? This illustration explains use of parallel sections construct. Three functions, fun1, fun2, and fun3, all can be executed simulta

Evaluation functions, Evaluation Functions: Evaluation functions calcu...

Evaluation Functions: Evaluation functions calculate approximately the score which can be prove of guaranteed if a particular world state is reached. Same like in chess, evalu

What is visibility give uml notation, What is visibility give UML notation?...

What is visibility give UML notation? Visibility refers to the ability of a process to reference a feature from another class and has possible valued of public, private, protec

What is traffic engineering, What is Traffic Engineering? Traffic engi...

What is Traffic Engineering? Traffic engineering gives the basis for analysis and design of telecommunication network to carry a specified traffic at an exact loss probability

Multi-threaded concurrency programming with threads, Your task is to implem...

Your task is to implement a memory manager that manages page reads and writes from multiple client threads. In the first programming task the memory manager keeps all the pages in

Vector-memory instructions-vector processing, Vector-Memory Instructions : ...

Vector-Memory Instructions : When vector operations with memory M are executed then these are vector-memory instructions. These instructions are denoted with the many function mapp

Explain about parallel programming environment, Q. Explain about parallel p...

Q. Explain about parallel programming environment? The parallel programming environment comprises of a debugger, an editor, performance evaluator, programme visualizer for incr

Can a vector have a component equivalent to zero, Q. Can a vector have a co...

Q. Can a vector have a component equivalent to zero and still have a nonzero magnitude? Answer:- Yes For example the 2-dimensional vector (1, 0) has length sqrt (1+0) = 1

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