Questions about sorting

I am studying sorting in an algorithm course. I need a hint because I really don’t know where to start with these two following questions. Any help is appreciated.

Suppose all integers are stored in a single linked list.

  1. Write a function Sort whose input is a pointer to the first node of a list of unknown length.

    List Sort(node *head)

    Your method should return its elements in a sorted list. Again, your method should not create any new nodes and should have time complexity O(nlogn).

  2. Suppose two (unsorted) arrays A[0…n – 1] and B[0…n – 1] together contain 2n distinct numbers. Describe a method to construct an array C[O..n – 1] such that for each index i E [O..n -1], A[i] is greater than exactly C[i] elements in the array B[0…n – 1]. Your method may use O(n) extra space and should have O(nlogn) running time.

Questions regarding Strife in L5R 5E

I’ll be directing a game of L5R for the first time and I have some questions about Strife at L5R 5e (the one by Fantasy Flight Games). I might have missed the answers in the core rulebook as I’ve been reading it jumping from one page to another, but I haven’t found the answers there.

1) Can I offer assistance (page 26) while I’m Compromised (Page 30)?

2) Can I keep results with Strife while I’m Compromised if I’m using assistance and my budies take Strife for me?

3) Regarding combat and stances (page 251), can I keep results with Strife if I’m using the void stance?

4) Also regarding combat and stances, does a success with strife count as a double success?

Thank you for your time reading my questions!

[ Politics ] Open Question : Check out the flu vs corona virus numbers. Remember: There were no shutdowns with the flu but shutdowns with coronavirus. Any questions?

CDC estimates that between October 1, 2019 and April 4, 2020 (6+ months) the flu killed between 29,000 and 62,000 people with NO SHUTDOWNS. Covid-19 has killed over 81,000 in 5 months WITH SHUTDOWNS.

optimize user interactions to solve ambiguity in natural language questions

am doing research about how to reduce user interactions with the system to solve ambiguities in natural language questions to retrieve data from databases. note: those systems for technical users to enable them to restore data from databases without knowing query languages. Anyone have a suggestion for reducing those interactions.

Bob has to find Alices hidden gold by questioning yes/no questions

I have this

Alice has n places to hide the gold v1,…,vn

Bob knows the probability of each place

Now Bob has to ask Alice YES/NO Questions to find the gold.

I have done it this way:

We order the placec by probability highest to lowest.

Now divide them by 2 so we have 2 sets

We ask whether it is in the high probability set or not

Now we divide by 2 again and ask if it is the highest one and so on

My prof told me that we have to get that he questions on average H(V) questions

But with this I am close with 2.576 to H(V)=2.47 but it’s not H(V) any better ways?

H(V) is the Entropy.

Questions on Hat of Disguise 2

Hat of Disguise from DMG Pg. 258:

Hat of Disguise: This apparently normal hat allows its wearer to alter her appearance as with a disguise self spell. As part of the disguise, the hat can be changed to appear as a comb, ribbon, headband, cap, coif, hood, helmet, and so on. Faint illusion; CL 1st; Craft Wondrous Item, disguise self; Price 1,800 gp.

Disguise from PHB Pg. 222:

You make yourself—including clothing, armor, weapons, and equipment—look different. You can seem 1 foot shorter or taller, thin, fat, or in between. You cannot change your body type. For example, a human caster could look human, humanoid, or like any other human-shaped bipedal creature. Otherwise, the extent of the apparent change is up to you. You could add or obscure a minor feature or look like an entirely different person.
The spell does not provide the abilities or mannerisms of the chosen form, nor does it alter the perceived tactile (touch) or audible (sound) properties of you or your equipment. A battleaxe made to look like a dagger still functions as a battleaxe.
If you use this spell to create a disguise, you get a +10 bonus on the Disguise check.
A creature that interacts with the glamer gets a Will save to recognize it as an illusion. For example, a creature that touched you and realized that the tactile sensation did not match the visual one would be entitled to such a save.

Mimic from Exemplars of Evil Pg. 21

Many villains specialize in avoiding detection so that they can work behind the scenes to achieve their nefarious goals. To this end, they spend a fair amount of time developing techniques to mask their appearance, at the expense of their normal training in foiling traps.
Class: Rogue.
Level: 1st, 3rd, 6th, 9th, 12th, 15th, and 18th.
Special Requirement: You must have a Charisma of 12 or higher to select this alternative class feature.
Replaces: If you select this feature, you do not gain the trapfinding ability.
Benefit: Once per day, you can use disguise self as a caster whose level equals your class level. At 3rd level and every three levels thereafter, you can reduce your bonus on trap sense by 1 to gain an additional use of mimic.
At your discretion, when using disguise self, you can spend two uses of the spell-like ability to produce the effect as a swift action rather than a standard action

  1. Can the Hat of Disguise be used to layer Disguises?
  2. If Rogue Trapfinding AFC Mimic is used in addition to the Hat of Disguise, how do they layer or which one takes precedence?

Questions on Hat of Disguise

Hat of Disguise from DMG Pg. 258:

Hat of Disguise: This apparently normal hat allows its wearer to alter her appearance as with a disguise self spell. As part of the disguise, the hat can be changed to appear as a comb, ribbon, headband, cap, coif, hood, helmet, and so on. Faint illusion; CL 1st; Craft Wondrous Item, disguise self; Price 1,800 gp.

Disguise from PHB Pg. 222:

You make yourself—including clothing, armor, weapons, and equipment—look different. You can seem 1 foot shorter or taller, thin, fat, or in between. You cannot change your body type. For example, a human caster could look human, humanoid, or like any other human-shaped bipedal creature. Otherwise, the extent of the apparent change is up to you. You could add or obscure a minor feature or look like an entirely different person.
The spell does not provide the abilities or mannerisms of the chosen form, nor does it alter the perceived tactile (touch) or audible (sound) properties of you or your equipment. A battleaxe made to look like a dagger still functions as a battleaxe.
If you use this spell to create a disguise, you get a +10 bonus on the Disguise check.
A creature that interacts with the glamer gets a Will save to recognize it as an illusion. For example, a creature that touched you and realized that the tactile sensation did not match the visual one would be entitled to such a save.

  1. If someone makes the save to disbelieve the illusion, can I make a new illusion with the hat that they will have to re-detect?
  2. Assuming the previous answer is a yes, how long until I can redo the illusion?
  3. When does the +10 to Disguise take effect?
  4. Can I use the hat to make Multiple effects that are layered?
  5. If a Rogue has the Mimic ACF and uses it, which illusion takes precedence?

Questions regarding CPU scheduling algorithms ( Round Robin and Priority scheduling )

Consider the following processes :

enter image description here

1) My First Question is if we need to schedule them using preemptive priority scheduling with Round-Robin for equal processes priorities with a quantum of 3. Here is my answer to this problem :

enter image description here

Sorry about that bad drawing. My problem here is at time 13. At this time we have two processes of equal priority ( p1 and p3 ) that we need to schedule them using RR with a quantum of 3 . My question is what process we will start scheduling it here ? I have started with p1 as it was already being executed by the CPU . Also is the rest of the answer is right ?

2) Now for the second question. Let’s consider that We need to schedule the same process with a round-robin with a quantum of 4 . I have used this website to check my answer http://cpuburst.com/ and here its answer : enter image description here

According to this answer, at time 20 p4 should be executed, but according to my answer p1 is the process that should be executed ?? And due to this difference, the rest of the answer is different to mine.

Does anyone know the answer the following questions on converting logical – physical addresses

Due to the unforeseen pandemic, I am unable to speak to my tutor about the following question. I have emailed him, but I have not had an answer for weeks. Can someone please enlighten me.

Image and question to be answered below. Please provide an explanation, as I am struggling to find an answer:

enter image description here