Redian新闻
>
小公司店面,面经分享
avatar
小公司店面,面经分享# JobHunting - 待字闺中
d*l
1
小烙印面试,烙印的口语真不好懂。
collabedit 上做题,题目是:
say we have a function named int badHeadsOrTails(), which returns 0 (60% of
the tiime), and return 1 (40% of the time).
Now, write a function - int goodHeadsOrTails(), which will return 0 or 1(
each 50% of the time), only using badHeadsOrTails() as the sole source of
randomness.
10分钟后,做出来了,独立事件概率。
还剩时间,烙印说,我再给你第二道看看,在屏幕上写出 check string is
palindrome..用 while loop。
avatar
A*e
2
第一题怎么做?

of

【在 d******l 的大作中提到】
: 小烙印面试,烙印的口语真不好懂。
: collabedit 上做题,题目是:
: say we have a function named int badHeadsOrTails(), which returns 0 (60% of
: the tiime), and return 1 (40% of the time).
: Now, write a function - int goodHeadsOrTails(), which will return 0 or 1(
: each 50% of the time), only using badHeadsOrTails() as the sole source of
: randomness.
: 10分钟后,做出来了,独立事件概率。
: 还剩时间,烙印说,我再给你第二道看看,在屏幕上写出 check string is
: palindrome..用 while loop。

avatar
t*r
3
投两次
HT -> H
TH -> T

【在 A*******e 的大作中提到】
: 第一题怎么做?
:
: of

相关阅读
logo
联系我们隐私协议©2024 redian.news
Redian新闻
Redian.news刊载任何文章,不代表同意其说法或描述,仅为提供更多信息,也不构成任何建议。文章信息的合法性及真实性由其作者负责,与Redian.news及其运营公司无关。欢迎投稿,如发现稿件侵权,或作者不愿在本网发表文章,请版权拥有者通知本网处理。