📣 独立日限时特惠: VIP通行证立减$68
12
返回列表 发新帖
楼主: easonchan1213
跳转到指定楼层
上一主题 下一主题
收起左侧

谷狗

🔗
 楼主| easonchan1213 2020-7-30 16:55:12 | 只看该作者
全局:
坨坨 发表于 2020-7-30 09:50
第一题矩阵里每个格子是只有1和0吗?还是可以是任意数?

是任意數字 -inf ~ inf 32bit integer
回复

使用道具 举报

🔗
cvfox4fun 2020-7-31 08:03:18 | 只看该作者
全局:
积分有点低,看不见,请问现在L4面system design吗?
回复

使用道具 举报

🔗
caramonmajere 2020-8-24 12:48:45 | 只看该作者
全局:
easonchan1213 发表于 2020-7-26 01:05
不一樣,你說的那題我面試前解過了,第二輪其實比較像這樣
consider a tree example:
1      3

所以input是1)directed graph 2)要删除的node,

那么output是 更新并返回3)指向node的节点 + 4)node指向的节点吗?

如果这样的话,3)需要进行遍历,4)是现成的,不知道理解的对不对。

回复

使用道具 举报

🔗
 楼主| easonchan1213 2020-8-24 18:41:04 | 只看该作者
全局:
caramonmajere 发表于 2020-8-24 12:48
所以input是1)directed graph 2)要删除的node,

那么output是 更新并返回3)指向node的节点 + 4)no ...

it's 3) & 4). 也就是要更新node指向的節點, but only remove nodes which has either
1) ingress degree = 0 or 2) has only 1 ingress degree and from deleted node
回复

使用道具 举报

🔗
橡皮擦 2020-9-5 07:49:03 | 只看该作者
全局:
本帖最后由 fdeng001 于 2020-9-5 08:45 编辑

请问楼主那道graph的题目,
input如果是List<GraphNode>的话,我觉得应该是,先把target的neighor的指向为null, 然后for loop 所有的node,如果node的neigbor有target的话,删掉target, 然后用unionfind找到 connect 的nodes
如果input是一个root的话,同理,删掉各种指向的edge,然后在用union find, 用union find可以解决如果有环的情况或者边dfs边做mapping
回复

使用道具 举报

🔗
Jess. 2020-10-17 08:33:23 | 只看该作者
全局:
easonchan1213 发表于 2020-8-24 18:41
it's 3) & 4). 也就是要更新node指向的節點, but only remove nodes which has either
1) ingress degre ...

1) ingress degree = 0 or 2) has only 1 ingress degree and from deleted node

这个听起来像toposort+bfs
回复

使用道具 举报

🔗
ReminderHan 2020-10-17 09:07:12 | 只看该作者
全局:
请问狗家L4是不面system design了吗
回复

使用道具 举报

地里匿名用户
🔗
匿名用户-HK4SX  2020-11-25 08:09:45
本帖最后由 匿名 于 2020-11-25 08:43 编辑

fairly well为什么被拒, 有咩有提供feedback。
回复

使用道具 举报

🔗
 楼主| easonchan1213 2020-11-25 10:17:38 | 只看该作者
全局:
匿名者 发表于 2020-11-25 08:09
fairly well为什么被拒, 有咩有提供feedback。

沒有為什麼,feedback就是不夠好, not good enough so they can't ignore you,下次再來。
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 注册账号
隐私提醒:
  • ☑ 禁止发布广告,拉群,贴个人联系方式:找人请去🔗同学同事飞友,拉群请去🔗拉群结伴,广告请去🔗跳蚤市场,和 🔗租房广告|找室友
  • ☑ 论坛内容在发帖 30 分钟内可以编辑,过后则不能删帖。为防止被骚扰甚至人肉,不要公开留微信等联系方式,如有需求请以论坛私信方式发送。
  • ☑ 干货版块可免费使用 🔗超级匿名:面经(美国面经、中国面经、数科面经、PM面经),抖包袱(美国、中国)和录取汇报、定位选校版
  • ☑ 查阅全站 🔗各种匿名方法

本版积分规则

>
快速回复 返回顶部 返回列表