-
拼多多一面
岗位:数据分析
1.自我介绍
2.华为实习经历
3.提前批为什么没有通过?
4.最近关于SQL有什么的提升?
5.SQL题目
-----+------------+-----------+
| 1 | 2017-01-01 | 10 |
| 2 | 2017-01-02 | 109 |
| 3 | 2017-01-03 | 150 |
| 4 | 2017-01-04 | 99 |
| 5 | 2017-01-05 | 145 |
| 6 | 2017-01-06 | 1455 |
| 7 | 2017-01-07 | 199 |
| 8 | 2017-01-08 | 188 |
+------+------------+-----------+
输出:连续3天 景点客流量大于100 的日期
select t1.date
from table t1
inner join( select t2.date d2, t2.people p2,t3.date d3, t3.people p3
from table t2
inner join table t3
on t2.date=t3.tate+1) t4
on t1.date=t4.date+2
where t1.people>100 and t2.people>100 and t3.people>100
6.智力题
房间内有 100 人,每人有 100 块,每分钟随机给另一个人 1 块,最后这个房间内的财富分布怎样?