Redian新闻
>
一道A家面试题 大家讨论看看
avatar
a*8
2
Write an algorithm to check the winning condition in a tic-tac toe game for
a NXN grid ?
requirement: time complexity o(1) space complexity no specified
avatar
p*2
4
就是用计数器吧?
avatar
s*s
5
Refurbished
上次有个神医收30块钱,被一堆护士骂了
avatar
j*y
6
只是让check 吧? 感觉check的时候,需要确定该谁下这一步,是自己下,还是对手下。

for

【在 a*****8 的大作中提到】
: Write an algorithm to check the winning condition in a tic-tac toe game for
: a NXN grid ?
: requirement: time complexity o(1) space complexity no specified

avatar
a*8
8

我想到的也是类似的思路 就是用数组来记录 每一行 每一列 两个对角线 上棋子的个


【在 p*****2 的大作中提到】
: 就是用计数器吧?
avatar
a*8
10

下。
恩 是的 所以我觉得还应该再加一套数组 来记录 比如说这一行的棋都是A下的 那么当
下次B 放棋到这行的时候 检测和原来的记录的玩家不一样 那么这行就不可能了

【在 j*****y 的大作中提到】
: 只是让check 吧? 感觉check的时候,需要确定该谁下这一步,是自己下,还是对手下。
:
: for

avatar
c*a
11
这个是自用的。。。
avatar
s*m
12
谢谢!就是不能买多个,搞多个rebate了。二手不是有人在收吗?
哎呀,只能买个自用了

【在 c*****a 的大作中提到】
: 这个是自用的。。。
avatar
m*r
13
limit 1?
normally it is 10

【在 s*****m 的大作中提到】
: 谢谢!就是不能买多个,搞多个rebate了。二手不是有人在收吗?
: 哎呀,只能买个自用了

avatar
t*g
14
limit 10

【在 m*r 的大作中提到】
: limit 1?
: normally it is 10

avatar
w*t
15
hot if new,, nothing hot 50 for refurbished one
avatar
z*5
16
用上coupon就是25。
这个自用的话,starting也能打几百张吧?用完tradein,可以了。。。

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