Stack Exchange network consists of 183 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.
Ask questions, find answers and collaborate at work with Stack Overflow for Teams.
Ask questions, find answers and collaborate at work with Stack Overflow for Teams. Explore Teams
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
set n 0 proc L f {puts [string repe \t $[expr [incr ::n][filen]-1]][file ta $f];incr ::n;lmap$f];lmap c [glob -n -d $f *] {L $c};incr ::n -1} L $argv
Try it online!Try it online!
set n 0 proc L f {puts [string repe \t $::n][file ta $f];incr ::n;lmap c [glob -n -d $f *] {L $c};incr ::n -1} L $argv
Try it online!
proc L f {puts [string repe \t [expr [incr ::n]-1]][file ta $f];lmap c [glob -n -d $f *] {L $c};incr ::n -1} L $argv
set n 0 proc L f {puts [string repe \t $::n][file ta $f];incr ::n;if [file isd $f] {lmapn;lmap c [glob -n -d $f *] {L $c}};incr ::n -1} L $argv
set n 0 proc L f {puts [string repe \t $::n][file ta $f];incr ::n;if [file isd $f] {lmap c [glob -n -d $f *] {L $c}};incr ::n -1} L $argv
#tcl, 137
testable on http://www.tutorialspoint.com/execute_tcl_online.php?PID=0Bw_CjBb95KQMU25pQzVGUUladmsTry it online!
testable on http://www.tutorialspoint.com/execute_tcl_online.php?PID=0Bw_CjBb95KQMU25pQzVGUUladms