Tech News World, Contacts Samsung Galaxy, Windows 8, Nokia Lumia, Quad Core Smart Phones, HTC smartphone, Google Nexus, MacBook, PayPal

Sunday, December 16, 2012

Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements

Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements - Although I work in the office and a lot of work that makes me tired but still I make a blog Tech News World and still will update it for you because this is part of my hobby who likes the world of technology, especially about the gadget, now we will discuss first about Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements because it is the topic that you are now looking for, please refer to the information I provide in the guarantee for you,

Articles : Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements
full Link : Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements

You can also see our article on:


Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements


For loops

For loops are very useful in ns and can be used in conjunction with arrays to easily create larger network topologies. To generate 100 nodes, the following code can be used:
for {set i 0}{$i < 100}{incr i} {
    set n($i) [$ns node]
}

While loops

These are very similar to for loops. The syntax is
set i 0
while {$i < 10} {
    set n($i) [new Node]
    incr i
}

If statements

If statements are very simple
if {$i < 10} {
    puts "i is less than 10"
}
if {$var2 == "Tcl Variable 2"} {
    puts "var2 = Tcl Variable 2"
}



so much information about Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements

hopefully information Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements can provide useful knowledge for you in getting information about the latest gadgets,

just finished your reading article about Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements if you feel this article useful for you please bookmark or share using link http://aziin5teens.blogspot.com/2012/12/tcl-and-otcl-tutorial-for-ns2-loops-and.html for more people know

Tag :
Share on Facebook
Share on Twitter
Share on Google+
Tags :

Related : Tcl and OTcl Tutorial For NS2 -Loops and Conditional Statements

0 comments:

Post a Comment