当前位置:网站首页>Leetcode:608 tree node
Leetcode:608 tree node
2022-07-06 09:34:00 【Prism 7】
List of articles
One 、code
1.1 Title Description
1.2 Answer key
# Write your MySQL query statement below
select
id,
case
when p_id is null then 'Root'
when id in (select distinct p_id from tree) then 'Inner' # When not in() It contains null value , The query will not return any value .
else 'Leaf'
end as type
from
tree
order by id
;
Two 、 summary
select case city_name
when ‘ Shenzhen ’ THEN ‘ south China ’
when ‘ Guangzhou ’ THEN ‘ south China ’
when ‘ foshan ’ THEN ‘ south China ’
when ‘ Hangzhou ’ THEN ‘ East China ’
when ‘ Shanghai ’ THEN ‘ East China ’
ELSE ‘ other ’
END AS temp,
边栏推荐
- Improved deep embedded clustering with local structure preservation (Idec)
- Basic concepts of libuv
- 六月刷题01——数组
- 七层网络体系结构
- Withdrawal of wechat applet (enterprise payment to change)
- Global and Chinese market of capacitive displacement sensors 2022-2028: Research Report on technology, participants, trends, market size and share
- Meituan Er Mian: why does redis have sentinels?
- Opencv+dlib realizes "matching" glasses for Mona Lisa
- [deep learning] semantic segmentation: paper reading: (2021-12) mask2former
- Advanced Computer Network Review(4)——Congestion Control of MPTCP
猜你喜欢
Improved deep embedded clustering with local structure preservation (Idec)
Hard core! One configuration center for 8 classes!
Redis之Lua脚本
Reids之缓存预热、雪崩、穿透
Activiti7工作流的使用
[deep learning] semantic segmentation: paper reading: (CVPR 2022) mpvit (cnn+transformer): multipath visual transformer for dense prediction
Oom happened. Do you know the reason and how to solve it?
Sentinel mode of redis
Redis之核心配置
Compilation of libwebsocket
随机推荐
【图的三大存储方式】只会用邻接矩阵就out了
O & M, let go of monitoring - let go of yourself
Redis之Geospatial
Sentinel mode of redis
Redis之五大基础数据结构深入、应用场景
Redis' bitmap
Design and implementation of online shopping system based on Web (attached: source code paper SQL file)
Oom happened. Do you know the reason and how to solve it?
[Yu Yue education] Wuhan University of science and technology securities investment reference
Minio distributed file storage cluster for full stack development
五月集训总结——来自阿光
LeetCode41——First Missing Positive——hashing in place & swap
go-redis之初始化连接
Seven layer network architecture
Appears when importing MySQL
【深度学习】语义分割:论文阅读:(CVPR 2022) MPViT(CNN+Transformer):用于密集预测的多路径视觉Transformer
068.查找插入位置--二分查找
[deep learning] semantic segmentation: paper reading: (CVPR 2022) mpvit (cnn+transformer): multipath visual transformer for dense prediction
Heap (priority queue) topic
DCDC power ripple test