title: Create nested for loops when the number of iterations are unknown
body: <p>I have json that is similar to this: </p>
  
  <pre><code>{
    Name: Level 1,
    Children: [
      {
         Name: Level 2,
         Children: [
          {
             Name: Level 3,
             Children: [
               {
                  Name: Level 4,
                  Children: [
                    {
                       Name: Level 5,
                       Children: []
                    }
                  ]
                }
              ]
            }
          ]
      }
    ]
  }
  </code></pre>
  
  <p>Currently the depth level is five, and I'm trying to use nested for loops similar to this:</p>
  
  <pre><code>for()
  {
     for()
     {
         for()
         {
              for().....
  </code></pre>
  
  <p>But I'd like to know if I there is a way to generate this without using so many for loops, because currently the depth level is five but could be more.</p>