• 发帖子
  • 发文章
成就云开发者社区|开发者社区
话题技术文章成就云
登录
头条面试题:计算目录树的深度
题目:前端在后台管理系统经常会用到目录树,求下面目录tree的高度。 const tree = { name: 'root', children: [ { name: '叶子1-1' }, { name: '叶子1-2' }, { name: '叶子2-1', children: [{ name: '叶子3-1', children: [{ name: '叶子4-1' }]
成就云发布于 2024-08-10 08:23:05
childrenpushtree遍历数组

© 2025 Attains Cloud. 成就云 版权所有

豫ICP备2021016866号-1