Advertisement
AnindyaBiswas

TCL 1st class

Apr 22nd, 2022
1,415
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
TCL 0.24 KB | None | 0 0
  1. set ns [new Simulator]
  2. set f [open out.tr w]
  3. $ns trace-all $f
  4. proc finish { } {
  5.     global ns f
  6.     $ns flush-trace
  7.     close $f
  8.     exit 0
  9.     }
  10. set n0 [$ns node]
  11. set n1 [$ns node]
  12. $ns duplex-link $n0 $n1 1mb 10ms DropTail
  13. $ns at 5.0 "finish"
  14. $ns run
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement