📄 example1.tcl
字号:
#example1.tcl#create a simulator objectset ns [new Simulator]#open a file for writing that is used for nam trace dataset nf [open out.nam w]$ns namtrace-all $nf#finish procedure that closes the trace file and starts namproc finish {} { global ns nf $ns flush-trace close $nf exec nam out.nam & exit 0}#execute the "finish" procedure after 5.0 seconds of simulation time$ns at 5.0 "finish"#start the simulation$ns run
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -