Deep copy object with Depth-First Search

后端 未结 0 475
天涯浪人
天涯浪人 2020-12-28 15:26

I trying to copy an object. I want to made it with algorithm Depth-First Search.

function dfs(data) {
  let stack = [];
  let res = {};

  for (let key in dat         


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题