[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

Interview Question Time

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 147
Thread images: 5

File: 1430721291515.jpg (23KB, 620x349px) Image search: [Google]
1430721291515.jpg
23KB, 620x349px
Hello /g/. If you already know this question or type of question, please do our fellow anon a favor and don't post the solution or bother. I remember a thread like this many years ago helped me a lot with getting into the interview question grind, and want to return the favor.

"You have a coin, continue to flip it until either TTH (tails tails head) or THH is outputted. Is one of these more probable to appear first? If so, which one and with what probability?"

Coding simulations are not allowed, also do not read through the thread until you really gave up.

Good luck bros. Hope some of you learn.
>>
>>56993942
When you say tth or htt you mean these three outcomes but in any order or in this exact order?
>>
Also i'd encourage you guys to try and maintain the mentality that you are REALLY in an interview when solving the question.
Imagine that this means landing your dream job. This has helped me quite a bit despite how useless it might seem.
>>
>>56993964
exact order, you shouldn't ask that question in a real interview, though, because it's pretty defined within the framing/wording of the problem. If order didn't matter, you could be sure they would tell you.
>>
Using a simple tree is 1/8 and the same probabilty imho
>>
>>56993990
Also a small tip to add onto this: Among this type of scenario, where you have two competing ideas as to what the logic is defined as, expect the more difficult one to be the one sought after. ESPECIALLY if one of these is trivial as fuck.

If something ever seems too trivial, in a way that seems it's too good to be true, it likely is.
>>
>>56994051
>Using a simple tree is 1/8
Can you explain how you got this? your logic?

>the same probabilty
explain your reasoning, you would be expected to in an interview.
>>
>>56993942
Ah, I see the trick now. Ashamed to say that it took me a few minutes, probably would've panicked in an actual interview.
>>
>>56994151
The chance of your first toss being t/h is .5, there are 3 tosses times them together.
>>
>>56994341
What trick? You ignore the first toss because it's the same for both?
>>
>>56994341
Thanks for not posting answer anon.
It's a pretty devious problem, I think you see now.
>>
hurr durr i figured it out guys. wow what a tricky one xDDDDDD
>>
>>56994367
Think about what happens when you fail a toss.
>>
>>56994412
My friend asked this at a top investment bank, very few got it correct.
But you're thankfully a special snowflake anon xD
>>
I code it so it flips all three before checking the combination.
>>
same probability
>>
>>56994445
i still dont fully understand this. What am i doing wrong?
They are three independent tosses from a fair coin. So shouldn't it be the same probabilty for both options?
>>
>>56993942
we don't have to consider the previous tosses because coin tosses are independent, so the previous tosses will not affect the probabilities of the three tosses that we want to look at.

for the last three tosses, we have these probabilities

htt
tht
tth
hht
hth
thh
ttt
hhh

so getting tth out of all eight outcomes or getting thh out of all eight outcomes have the same 1/8 probability.

since they have the same probabilities, their geometric probability distribution is the same, so they are equally as likely to appear first in a test.

t. stat 100
>>
>>56993942
I am going to incorporate this question into my interviewing, but as a bonus question.

Thank you.
>>
Fucking shit interviewer scum. Kill yourself hr faggot
>>
sooo... The probability of getting TTH is equal to the probability of getting TT?
>>
>>56993942
TTH because both need TH to happen in the sequence. So TTH has a higher chance of getting matched because if TH happens at any time during the sequence he has a 50/50 of winning, it's only if he loses his 50/50 that the next coin flip happens and THH gets his 50/50 to get matched?
>>
>>56994591
Like, there being a sequence of numbers is really important in the question. It means we're looking at matching patterns but not just pure probability of these sequences happening.
>>
It's clearly 1/7 do you even binominal distributions
>>
>>56994542
*assuming the coin is fair
>>
>>56994522
Read the question, carefully, as fuck. don't read the other posts in this thread or you won't internalize it properly.
>>
>>56994553
I can't wait to interview people with this question. Definitely my favorite, and is pretty hilarious to hear how people think through it.
>>
>>56994655
I cannot wait to get 1 developer who can do easier-than-fizzbuzz.
>>
>>56994677
Is it really that bad? How big/prestigious is the company?

Yeah plenty of people can't code for fucking shit, but it's way more commonly seen at jobs that the smart engineers tend to avoid which means low pay or shit company.
>>
ITT: the people who unironically do Fizzbuzz get BTFO
>>
>>56994684
Just a standard web developer position, with a middle class salary, but in a third world country.

They cannot answer this question:
>Count down from 700 to 200, in decrements of 13
>>
>>56994703
Count out loud subtracting 13 every-time?
Or build a for loop that decrements by that amount?

Either way, fuck anon. Which continent is your country? What is the reason for failing elementary programming?
>>
>>56994757
Turns out that the best liars are the ones who get interviews, not the best programmers.
>>
Ok, I get that TTH is ultimatley more likely, since the possibility of success each step eliminates sequences ending in TH but not TT, meaning the next step (after the first) will always be more likely to have TTH, but I'm trying to figure how to boil this down to an exact probability through combinatorics.
>>
>>56993942

Damn this broke my brain a little. Got it now. Think of what happens after the initial three flips guys. What are the chances of each now?
>>
Going in for a junior web dev interview. HTML/CSS/JS. What are the types of questions which could pop up? I can make stuff and make them look good but I'm absolutely shit at algorithms and interview questions.
>>
>>56994821

TTH has double the chance of happening. Flip 4 coins. TTH comes up 1/4 and THH comes up 1/8.
>>
>>56994887
>What are the types of questions which could pop up

"Do you have a portfolio?" and "Do you know <framework>?"

There
>>
You guys are aware interviewers care less about the answer and the thought process that goes into solving the problem right?
>>
TTH THH
So I flip a coin three times, with a 1/8 chance of getting it.

I don't get either of the sequences, after that there is a maximum of two (TT or TH) of the sequence done already and a minimum of 0 (if the second & third toss was heads).

If TH were the final two tosses of the first three it means I would have a 1/2 chance of getting the THH sequence on the fourth toss

If TT was the final two, it would be the same 1/2 chance for the fourth toss

But if the final two were HH it means that it would be a 1/8 chance of getting it as none of those permutations are part of the sequence.

If it was HT then there would be a 1/4 chance of the following two being tails and heads.

So TTH is easier to get? Am I overthinking it?
>>
>>56994757
The full question:
>In ANY language of your choice, write a program to count from 700 down to 200, in decrements of 13.

If they stare at me blankly for more than a few seconds, I add:

>So the expected output is 700, 687, 674, and so on. Use any language, and any method you like. Do not worry, it does not have to be 100% correct, I just want to see your code.

Also: Asia.

>What is the reason for failing elementary programming?
Based on what I have seen when visiting multiple universities and colleges here (including the best universities), you can pass a programming course via pure cut/paste. This seems to hold true in other countries as well. Actually learning programming, or failing a programming course when you cannot learn it, is a very rare thing.
>>
>>56994903
How?

TTH and THH are 1/8 respectively (2/16)
Of the remaining possibilities, TTT and HTT will resolve to TTH on the forth flip given a H, while only HTH will become THH, adding 2/16 and 1/16 respectively to make 4/16 and 3/16. I could see it going to 2/3 in the limit though.
>>
>>56994909
Just those? I know it's a junior position, but still
>>
>>56994932

For serious? People fail that? I should be surprised, but I'm not actually.
>>
>>56994996
Start at T.

1 flip-
TT (no fail)
TH (no fail)

2 flip-
TT -> TTH (win)
TT -> TTT (no fail)

TH -> THT (fail, restart at T)
TH -> THH (win)

3 flip-
TT -> TTT -> TTTT (no fail)
TT -> TTT -> TTTH (win)

4 - Repeat 3.

In other words: After getting a TH, you can fail and restart from T. After getting a TT, you are guaranteed a TTH.
>>
>>56995040
Yes, exactly those.

If you don't have a portfolio worht naming then prepare a speech on how you dabble with everything and get a chance to namedrop stuff (while still being able to go into detail).
>>
>>56994996

You are right and I'm fucking stupid. I got the logic right but the answer wrong.
>>
>>56994572
of course not. TTH is less likely than TT because you need another 50% variable to go your way.
>>
>>56994923
Not for this question. You either get it, or you don't. Not really an in-between.

Still important to think out loud though, just less important than most others.
>>
>>56995062
My latest miserable interview ended after this:
>Can you write a program to show the 12 times table?
I pulled up the 12x12 table on my screen and showed it to him.

...he tried to

 
printf("1 2 3 4 5 6 7 8 9 10 11 12");
printf("2 4 6 8 10 12 14 16 18 20 22 24");
etc


The other guy who was helping me interview suggested 2 nested for loops, but we might as well have asked for the moon.
>Nested loop? What's mean nested? How to do?
>>
>>56995124
>Can you write a program to show the 12 times table?
This is still easy as fuck but I would say harder than fizz fucking buzz.

You should do phone interviews before you bother with these idiots.
Also how much these positions be paid, out of curiosity?
>>
>>56995220
>You should do phone interviews before you bother with these idiots.
I do. It filters half.

Pay is "comfortable middle class", but third world scale.
>>
>>56995065

Oh cool it makes a lot more sense that way
>>
>>56995101
Yes it is. After TT, no matter what happens, you'll get an H eventually (or an infinite sequence of T, with probability 0), giving you TTH.
P(...TTH | TT) = P(TTH) + P(TTTH) + P(TTTTH) + ... = P(TT)
>>
you forgot the side of the coin

and chaos magic doesn't magically change the probability of the next throw from 50/50(or side of coin) despite what wikipedia and some old math guy said.
>>
Am i correct in saying that thh has a 1/4 chance while tth has a 1/3 chance?
>>
>>56995066
well thanks anon, I really hope you're right!
>>
You said no coding simulations, but I was trying to work out whether you were full of bullshit and the chances were equal, or whether there is actually a trick to this question.

After ten million trials, here are the results:
TTH occurred first:    5000732    (50.007%)
THH occurred first: 4999268 (49.993%)


In short then, it's a shitty question, because the answer is obvious.
>>
>>56995415
Show me the code.
>>
>>56995415
Tisk Tisk.
Anon, you didn't program the proper logic behind the question.
I'll give a hint: You are thinking of the flips as groups of three, instead of a RUNNING three.
A stream of flips. You're not generating an array of size 3 everytime, that's not a stream of flips as the question implies.
>>
>>56993942
Any sequence of n length is just as likely to appear at any time as any other sequence of the same length.
>>
>>56995464

Yes, I'm (probably) shit at programming. (Also there were too many lines so I had to remove the blank ones and attach the braces.)

using System;
using System.Collections;
using System.Text;
class Coins {
static void Main() {
Random random = new Random();
Log log = new Log(3);
uint TTH = 0;
uint THH = 0;
for (int i = 0; i < 100000000; ++i) {
if (i % 1000000 == 0)
Console.WriteLine("{0}...", i);
while(true) {
log.Add(random.Next(0, 2) == 0 ? false : true);
if (log.ToString() == "TTH") {
++TTH;
break;
}
if (log.ToString() == "THH") {
++THH;
break;
}
}
}
Console.WriteLine("TTH occurred first:\t{0}\t({1:00.000}%)", TTH, (double)TTH / ((TTH + THH) / 100.0));
Console.WriteLine("THH occurred first:\t{0}\t({1:00.000}%)", THH, (double)THH / ((TTH + THH) / 100.0));
}
}
class Log {
private bool?[] log;
private int currentIndex = 0;
public Log(uint size) {
if (size == 0) {
throw new ArgumentException("Log size cannot be zero.", "size");
}
log = new bool?[size];
for (int i = 0; i < log.Length; i++)
log[i] = null;
}
override public string ToString() {
StringBuilder sb = new StringBuilder("");
for (int i = currentIndex; i < log.Length; ++i) {
switch (log[i]) {
case true:
sb.Append('T');
break;
case false:
sb.Append('H');
break;
default:
sb.Append('-');
break;
}
}
for (int i = 0; i < currentIndex; ++i) {
switch (log[i]) {
case true:
sb.Append('T');
break;
case false:
sb.Append('H');
break;
default:
sb.Append('-');
break;
}
}
return sb.ToString();
}
public void Add(bool toAdd) {
log[currentIndex] = toAdd;
if (currentIndex == log.Length - 1)
currentIndex = 0;
else
++currentIndex;
}
}
>>
>>56995477
Yes I am. I'm generating unlimited flips, and constantly checking the most recent three.
>>
>>56995378
No.
>>
>>56995124
Hold on did the guy getting interviewed not understand nested loops? Is that what you are saying?
>>
>>56995477
>>56995507
pwned
>>
>>56995498
Anon learn some python, it's meant for shit like this and takes at least half as long to program out.
Jesus christ, I have sympathy for you to type all that shit out.
>>
>>56995498
no reason this can't work, your actual problem is the random generator, computers don't into real random very easily.

...when I said the probability is 50/50 on each throw individually instead of math magic I didn't expect code to back me up...wikipedia btfo.
>>
>>56993942
When you roll TT, the following roll can be H or T. If it's H, you get TTH, and the simulation is over. If you get T, you get TTT, and the next roll again has 50% chance to end the simulation finding TTH. With TH such thing does not happen - if you roll T, whatever you roll after, you have no chance to find THH (you can find HTH and HTT).

Hence TTH should be more likely.

In fact if you roll TT you are railroaded into getting TTH - nothing else.

I don't know the probability but I'd say around 68% for TTH.
>>
File: Untitled2.png (52KB, 1361x771px) Image search: [Google]
Untitled2.png
52KB, 1361x771px
>>56995498
I cannot read this! Good grief, man! Anyway, here is something very simple I cooked in the meantime.
>>
>>56995557
Oh hey I'm 1% off then.
>>
>>56995566
It is not 50/50, it is 66/33.
>>
>>56995583
It's 67/33.

My estimation was somewhere around 68.
>>
>>56995557
There's probably a better solution than using that 'log' class. All it is is an array of fixed size which overwrites the oldest elements when you add too many. It's of size three, meaning that you call the 'add' method each time you flip a coin, and the log will hold the most recent three (though it might start in the middle of the log and wrap around, but the ToString method takes care of that.)
>>
>>56995589
I was replying to this guy: >>56995415
>>
Fairly obvious that TTH is more likely since the first two characters of THH is a suffix of TTH and not vice versa.
Anyways, common lisp; consistently getting 0.666:
(defun t-or-h ()
(let ((x1 (random 2))
(x2 (random 2))
(x3 (random 2)))
(labels ((tth ()
(and (eq x1 1)
(eq x2 1)
(eq x3 0)))
(thh ()
(and (eq x1 1)
(eq x2 0)
(eq x3 0))))
(loop
until (or (tth) (thh))
do (progn
(setq x1 x2)
(setq x2 x3)
(setq x3 (random 2))))
(tth))))

(defun bool-to-num (x)
(if x 1 0))

(/ (loop for x from 1 to 1000000
summing (bool-to-num (t-or-h)))
1000000)
>>
>>56995547

It's actually 2/3 so 67% rounded up.
>>
>>56995605
I was replying to you.
>>
>>56995557
I wonder what I was doing wrong?
>>
>>56995619
I do not know. For such a simple problem, your code is too verbose to scrutinise (assuming you are the 50/50 Java guy).
>>
>>56995612
Yeah, just got that.

do{
while(1){
$_.=('H','T')[rand 2];

$scores[0]++,last if /TTH$/;
$scores[1]++,last if /THH$/;
}
} foreach 1..300000;

print join ", ",@scores;


b:\>perl tt.pl
200082, 99918
b:\>
>>
>>56995626
I'm pretty sure that's C#.
>>
instend of a simulation
we know there is a fifty-fifty chance for each flip
so we know that in each flip of three the probabilitiy of THH and TTH can be represented as (.5)^3
>>
>>56995635
My bad.
>>
>>56995640
That does not look like a solution and you did not post an answer.
>>
>>56995640
or for each three flips there is a 0.125%
of a THH or TTH
>>
>>56995653
im sorry im a newfag in general
>>
>>56995667
>>56995658
Not only you are a newfag, your solution is also incorrect.
>>
>>56995677
what do you think would be a better solution seeing as coding simulations are not allowed
>>
>>56995689
Thinking.
>>
>>56995689
My reasoning is posted here: >>56995547
Solution would definitely take things I elaborate on in consideration.
>>
>>56995722

not to be rude but i think your reasoning is flawed
you do not take into account the probability of the first two flips
>>
Here are as clean a simulation and explanation as I could write:

from random import randint as ri

# ri(0,1) gives 0 or 1 with a 50% chance. 0 is Heads ('H'), 1 is Tails ('T').

def testing_these_flips():

# the variable 'state' will indicate where we are in the game.
# There are four states :
# 0, no interesting sequence (i.e 'HHHHH...');
# 1, the current sequence is 'T';
# 2, the current sequence is 'TT';
# 3, the current sequence is 'TH';
# 4, the current sequence is 'TTH' or 'THH'.

state = 0 # we just started playing
while not state==4: # while 'TTH' or 'THH' haven't appeared yet
if state==0: # if no T has happened yet
if ri(0,1): state=1 # if we get 'T' then the sequence becomes 'T'
if state==1: # if the current sequence is 'T'
if ri(0,1): state = 2 # if we get 'T' then the sequence becomes 'TT'
else: state = 3 # if we get 'H' then the sequence becomes 'TH'
if state==2: # if the current sequence is 'TT'
if not ri(0,1): # if we get 'H' then the sequence becomes 'TTH' and we stop
state = 4
res = 'TTH'
if state==3: # if the current sequence is 'TH'
if ri(0,1): state=1 # if we get 'T' then the sequence becomes 'T' again
else:
state = 4 # if we get 'H' then the sequence becomes 'THH' and we stop
res = 'THH'
return res # the return statement gives 'TTH' or 'THH' when the game stops


# Testing the stuff
t = [0,0]
for i in range(10000):
if testing_these_flips()=='TTH': t[0]+=1
else: t[1] +=1

print(t)


Output:
[6668, 3332]


'TTH' is twice as likely as 'THH'.
>>
>>56995745
In the first place, the amount of flips is not strictly defined. You are not guaranteed to have 3 flips.

>>56995498
And I found your error. after each run, you are supposed to reset the sequence, setting all values in your log thing to nulls. You don't do that.
>>
>>56995764
my solution is to flips of three
for a solution for N flips i think it may be np-hard
>>
>>56995786
Your solution is to a problem that's completely unrelated to the problem posted in OP. You did not even understand it.
>>
>>56995793
anon you just made me realise you are quite correct.
im more than a new fag im a iliterate fag
>>
>>56994684
>Is it really that bad?
Ho hum yes.
What's worse is that developers are in high-demand, at least on third world countries, so the good ones will also often refuse you, since they are taking several other interviews too.

Damn, a tech startup sure is suffering.
>>
>>56995817
That's the part people fuck up the most.

IF IT'S TOO GOOD/EASY TO BE TRUE, IT IS.
When someone asks this question, your first instinct should be "NO way are they the same. How could I come to understand why the probabilities might be different?"
>>
>>56995845
the thing that screwed me up was the fact
both sequences had two of the same
so i made it out as the two first flips having the same probability
rip my brain
>>
File: csgraduate.png (60KB, 413x433px) Image search: [Google]
csgraduate.png
60KB, 413x433px
>>56994932
>The full question:
>>In ANY language of your choice, write a program to count from 700 down to 200, in decrements of 13.

<?php
$array = array();

for ($i=200; $i<=700; $i++) {
if ($i == 700 || $i == 687 || $i == 674 ||
$i == 661 || $i == 648 || $i == 635 ||
$i == 622 || $i == 609 || $i == 596 ||
$i == 583 || $i == 570 || $i == 557 ||
$i == 544 || $i == 531 || $i == 518 ||
$i == 505 || $i == 492 || $i == 479 ||
$i == 466 || $i == 453 || $i == 440 ||
$i == 427 || $i == 414 || $i == 401 ||
$i == 388 || $i == 375 || $i == 362 ||
$i == 349 || $i == 336 || $i == 323 ||
$i == 310 || $i == 297 || $i == 284 ||
$i == 271 || $i == 258 || $i == 245 ||
$i == 232 || $i == 219 || $i == 206) {
array_push($array, $i);
}
}

$array = array_reverse($array);

foreach ($array as $element) {
echo $element . '<br>';
}
>>
>>56995749
perfect
>>
>>56995863
That's amazing.
>>
When I had to come up with written interview questions, I went to /dpt/ and copied few snippets from there.

Questions were in form of "This program is supposed to do X, but doesn't. Fix the mistake."
>>
>>56995845
You're over thinking a simple question.

THTH =\= THH. They asked for the probability of two sequences of the same length. Not the probability of whatever non sequence you're trying out.
>>
>>56995932
The answer is TTH is more likely and has probability of 2/3. It's not a simple question and mathematical solution to it is not very simple either.
>>
>>56995932
wait does that mean the (.5)^3 is correct by that logic?
>>
>>56995958
Didn't you already write that you understand you were incorrect?
>>
>>56995932
huh? what am I reading?

The answer is TTH is more likely because the win conditions for TTH is REALLY just TT.

You can keep getting Ts, TTTTTTT, but eventually you HAVE to hit an H. TT is all you really need. You can't say the same with THH.
>>
>>56995971
yep your right im tired
should sleep before i make a mess of myself
this is what happens when a highschooler trys to do math outside his reach
>>
>>56995997
This is not really math since no one really did math in this thread.

This is in your reach. Not an exact solution but at least an estimation.
>>
>>56993942
Flip 1: H
Flip 2: T
Flip 3: T
Flip 4: H

We've reached TTH before we had a chance at THH. TTH is more probable.
>>
>>56995958
Yes. Since heads and tails have equal probability of happening, any sequence of n length is just as likely as any other sequence of that same length. The probability P, of each sequence is given as p to the nth power, where p is the probability of a specific result in a one toss game.
>>
this thread made me realize im a complete retard
>>
>>56996021
Flip 1: H
Flip 2: T
Flip 3: H
Flip 4: H

We've reached THH before we had a chance at TTH. THH is more probable.
>>
>>56996031
me 2
night
>>
>>56996021
pls be troll
>>
>>56996025
Honestly can't tell at this point this is just a poor attempt at trolling or someone's honest opinion. I guess since the first post in that chain is not his first post in the thread, it's gotta be trolling.
>>
>>56995749
from random import randint

def main():
charset = ["T", "H"]
matches = ["TTH", "THH"]
sequence = "".join([charset[randint(0, 1)] for i in range(0, 3)])
while sequence[-3:] not in matches:
sequence += charset[randint(0, 1)]
return sequence[-3:]


result = {"TTH": 0, "THH": 0}
for i in range(0, 1000000):
val = main()
result[val] += 1


{'THH': 333344, 'TTH': 666656}
>>
>>56995988
>>56996098
Okay, makes sense. I was wrong.
>>
>>56996098
Nice
>>
>>56996098
This reminds me why I laugh at faggots who shitpost about python.
Clean, I like it anon.
>>
>>56993942

This is Penney's game btw. Google it.
>>
>>56995749
thanks cpt obvious.
You missed the part about "no simulation" though.

It is a question about you being able to see patterns, not concluding on a simulation.
>>
>>56996533
thanks cpt obvious.
You missed ten hundred billion other posts in this thread doing the simulation.
>>
>>56994591
No, and you've been blacklisted from all programming companies now.
>>
>>56995988
Best explanation ITT
>>
>>56994703
>>56994932
so you mean
for(int i = 700; i > 200; i -= 13){ /*something*/ }
and they still fail?
fun fact: In R, it is implemented in the function seq, so you would have to write
seq(700,200,-13)

If you want to improve it, force people to use a for loop from 0 to 38, maybe as a followup question.

I have met a lot of people who trip up at very basic tasks, especially if they are put on a tiny bit of pressure.
>>
>>56995988
For anyone who still doesn't get it, just fucking read this.

If you don't understand just give up. It can't be explained in a more basic way.
>>
>>56996296
Neat. Thanks anon. Non transitive games like that boggle my mind.
>>
>>56996717
>they still fail?
Yes.

See >>56995841

There are more programming jobs than there are programmers. Sure, there are 10 times more "cs graduates" than there are jobs, but 99% of those graduates cannot do ANY programming AT ALL.
>>
>>56996793
a more basic way would be to point out that they both start with T, so you can break it down to TH vs HH.
>>
>>56996793

If people still don't get it:

https://www.youtube.com/watch?v=Sa9jLWKrX0c
>>
/g/ can't do basic stats.
>>
>>56993942
Yes.

Which one do you want?

The tails is more likely under a uniform distribution as the head side is slightly heavier, thus lands in the bottom more often.

However if I am flipping the coin I can apply a non-uniform launching force and adjust the height so one out come is significantly favored over the other.

So which side does it need to land for me to land this job?
>>
>>56997408
Congrats anon!
We are happy to announce that you will receive your certification of autistic tendencies!

Before we call your mom to pick you up, what flavor of ice cream would you like? Sprinkles?
>>
>>56997435
You might want to rethink that. I was thoroughly tested and shown to not be autistic. I am interested in how you reach such a erroneous conclusion.

Also Mom's on her wild 66 birthday tour with here friends for the next week in Mexico, so I very much doubt you can reach her and more so if she'd come shes been planning that thing for a few years.

If the offer for ice cream still stands I like strawberry.
But no sprinkles, I have a very nasty allergy to the wheat binding agent they are made of.
>>
>>56994542
wrong.
>>
>>56993942
Interesting , I liked it.
>>
File: 1424477746809.png (246KB, 550x535px) Image search: [Google]
1424477746809.png
246KB, 550x535px
>>56995498
>>
>>56994542
>coin tosses are independent
>their geometric probability distribution is the same

This is probably a common trap - unless you're doing these test tosses in sets of 3, you can't apply the geometric distribution to them and the outcomes are not independent of the previous tosses.
>>
fizzbuzz: math edition.
and /g/ failed
>>
>"You have a coin, continue to flip it until either TTH (tails tails head) or THH is outputted. Is one of these more probable to appear first? If so, which one and with what probability?"

No. Both have a 1/8 chance.
>>
>>57002440
this is not correct anon.
>>
>>56993942
Both have same probability of 0.125. That is assuming the exact order
>>
>>57003862
No, that's not correct. Try again.
>>
>>57003912
Ah I got it. TTH is more probable as it has a subsequence "TH" which is shred in both of them last. TH has to happen for both and if it's preceded with T, TTH will happen faster.

cba to calculate the probability
Thread posts: 147
Thread images: 5


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.