c programming, 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 programming

DoDAF OV-2 for a green datacenter, How do I create a DoDAF OV-2 for the con...

How do I create a DoDAF OV-2 for the construction of a green data center?

Operation of micro controller, Consider the hardware design as shown. Withi...

Consider the hardware design as shown. Within the target system the EPROM would contain the hex data as shown below   Address  Assembly code   8000             86   8001

The current image in gimp, How do we merge an image from a file to the curr...

How do we merge an image from a file to the current image in GIMP? Ans) Use "File then Open as Layers" menu command or just take the file to a window and drop it there. The file w

Perform division in binary showing contents of accumulator, Q. Perform divi...

Q. Perform division in binary showing contents of accumulator, B register and Y register during each step. (Accumulator, B, Y are 5-bit registers) 13 / 2

Define process of instruction execution, Instruction execution is performed...

Instruction execution is performed in CPU registers. Although before we define process of instruction execution let's first give details on Registers (temporary storage location in

Simplify the Boolean expression, The Boolean expression A‾.B + A.B‾ + A.B i...

The Boolean expression A‾.B + A.B‾ + A.B is equivalent to ? Ans. The Boolean expression A‾ .B + A. B‾+ A.B is equivalent to A + B (A‾ .B + A. B‾+ A.B = B( A‾ + A) + A. B‾ =

How blocking and non blocking statements get executed, How blocking and non...

How blocking and non blocking statements get executed? Execution of blocking assignments can be viewed just like a one-step process: 1. Evaluate RHS (right-hand side equatio

Data validation and data transfer, Data Validation condition: The following...

Data Validation condition: The following condition stated below must be met for a data to be valid as is shown in the figure 3a below. 1. The data on the SDA line must remain stabl

Write the binary representation of an integer number, The integer n = 3,510...

The integer n = 3,510,593 has hexadecimal representation 0x00359141 (check this with your d2h program), while the double precision, floating-point number 3510593.0 has hexadecimal

Is it possible to change the color and font of the sheet tab, Yes we can mo...

Yes we can modify the color of sheet tabs. By right clicking on sheet tabs and you will get option change color but you didn't find any option to modify the font of sheet tabs.

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