Guest User

Untitled

a guest
Sep 14th, 2018
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.26 KB | None | 0 0
  1. Do-while in Expect script
  2. #!/usr/bin/expect
  3. set val 0;
  4. set input 5;
  5.  
  6. do {
  7. puts "nval = $val"
  8. set input [expr $input-1];
  9. set val [expr $val+1];
  10. } while {input}
  11.  
  12. while true {
  13. puts "nval = $val"
  14. incr val
  15. if {[incr input -1] == 0} break
  16. }
Add Comment
Please, Sign In to add comment