A-M baby
This commit is contained in:
parent
764da6cbbb
commit
db842d013d
19005 changed files with 197040 additions and 7 deletions
6
Task/Loops-For/Tcl/loops-for-1.tcl
Normal file
6
Task/Loops-For/Tcl/loops-for-1.tcl
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
for {set lines 1} {$lines <= 5} {incr lines} {
|
||||
for {set i 1} {$i <= $lines} {incr i} {
|
||||
puts -nonewline "*"
|
||||
}
|
||||
puts ""
|
||||
}
|
||||
3
Task/Loops-For/Tcl/loops-for-2.tcl
Normal file
3
Task/Loops-For/Tcl/loops-for-2.tcl
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
for {set i 1} {$i <= 5} {incr i} {
|
||||
puts [string repeat "*" $i]
|
||||
}
|
||||
4
Task/Loops-For/Tcl/loops-for-3.tcl
Normal file
4
Task/Loops-For/Tcl/loops-for-3.tcl
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
set line ""
|
||||
for { set io [open test.txt r] } { ![eof $io] } { gets $io line } {
|
||||
if { $line != "" } { ...do something here... }
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue