Forum comments in chronological order

Disclaimer: I am not responsible for what people (other than myself) write in the forums. Please report any abuse, such as insults, slander, spam and illegal material, and I will take appropriate actions. Don't feed the trolls.

Jag tar inget ansvar för det som skrivs i forumet, förutom mina egna inlägg. Vänligen rapportera alla inlägg som bryter mot reglerna, så ska jag se vad jag kan göra. Som regelbrott räknas till exempel förolämpningar, förtal, spam och olagligt material. Mata inte trålarna.

Dec 2015

A lateral-thinking puzzle

lft
Linus Åkesson
Tue 1-Dec-2015 23:00
A fair point. Yes, that assumption should have been spelt out.

The TTY demystified

Anonymous
Fri 4-Dec-2015 08:14
Very nice summary for those born too late :-)

It might be worth mentioning that UARTs/serial ports have control lines to block transmission when the received data can't be processed as fast as it's received.
This way the UART itself would stop transmitting and the whole process was handled in hardware.
The sending process would have to wait (be blocked) for the UART to transmit it's data anyway, as the hardware would mostly be slower than the software anyway.

However when modems came in to play, the terminals UART and the hosts UART were no longer directly wired to each other and modems would only transmit data and no control lines between them. This situation required another method of flow control that would have to be transmitted in-band with the data. So software flow control via device control characters was invented.

A lateral-thinking puzzle

Anonymous
Thu 10-Dec-2015 16:49
I reached 5/3, assuming that drawing blood enough to give transfusion to 2 persons does not kill patient immediately.

Define patients 1, 2 and 3. Draw and store blood from each of them. Give blood of patient 1 to 2, and if he survives, also to patient 3. If patient 2 does not survive, give his stored blood to patient 3. If patient 3 does not survive, give his stored blood to patient 1, but if patient 3 survives, give patient 2's blood also to patient 1.

List of scenarios with (1,2,3) marking blood types of each patient:

(o,a,b),(o,b,a): Patients 2 and 3 both survive, 1/3 cases.
(a,b,o),(b,a,o): Patient 1 survives, 1/3 cases.
(a,o,b),(b,o,a): Patients 1 and 3 both survive, 1/3 cases.

1/3*2+1/3*1+1/3*2=5/3
lft
Linus Åkesson
Fri 11-Dec-2015 14:38
That's an interesting approach! But I'm not entirely convinced about the third case. Let's assume (a,o,b). In the beginning, each patient lacks 1 transfusion's worth of blood. After the initial drawing, each patient lacks 3 units of blood. You use one of the stored units of Type A blood, giving it to Patient 2. Then you give one unit of Type O blood to Patient 3. Finally, you give the remaining unit of Type O blood to Patient 1. At this point, I assume that any leftovers are given back to the respective patient, so the two stored units of Type B blood are given to Patient 3. But you only have one unit left of Type A blood, so Patient 1 would still end up lacking one unit of blood. You'd have to transfuse some of the blood from Corpse 2 back to Patient 1. That may or may not work in real life (please don't try it), but it's lateral thinking all right. If it was part of the intended solution, then I think it would have been good to spell it out. Otherwise; did I miss something?
Anonymous
Fri 11-Dec-2015 14:54
Hi Linus,

You're right about giving leftover blood back to donor, and the needed assumption I missed to state is actually based on original rules:
Patient A's blood will instantly kill Patient B and/or Patient O.
Patient B's blood will instantly kill Patient A and/or Patient O.

So, we can assume that virtually a drop of blood is enough to see the potential negative effect, and transfusion can be stopped without consuming any significant amount of blood. We need to draw blood from everyone just to avoid contaminating patient O's blood with even a single drop of wrong type.

-Pets
lft
Linus Åkesson
Fri 11-Dec-2015 16:40
All right, then I follow you. Good work there!