Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!samsung!emory!mephisto!ncsuvx!mcnc!rti!ntpdvp1!dallasb From: dallasb@ntpdvp1.UUCP (Dallas Braxton) Newsgroups: comp.unix.questions Subject: K-shell variables & Do-loops Keywords: K-shell, variables, do-loops, ksh, vars Message-ID: <339@ntpdvp1.UUCP> Date: 8 Feb 90 17:40:39 GMT Distribution: usa Organization: Northern Telecom DMS-10 Div., Raleigh, NC Lines: 20 I'm writing a shel script using K-shell with do loops, and I want to be able to "export" variables from the loop to the main body. Example: var1=yes # ... i=1 while i<2 do # ... var1=no i=i+1 # ... done echo $var1 I get "yes". How does one get "no"? Dallas Braxton Reply by e-mail to: ...!uunet!mcnc!rti!ntpdvp1!dallasb