# While loop problems

**URL:** <https://community.unix.com/t/while-loop-problems/162663>\
**Category:** Shell Programming and Scripting\
**Created:** [June 20, 2006, 4:26pm UTC](https://community.unix.com/t/while-loop-problems/162663 "2006-06-20T16:26:20Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![rcunn87](https://community.unix.com/letter_avatar/rcunn87/32/6_22734026db12803ebb3e059622ac3534.png) [@rcunn87](https://community.unix.com/u/rcunn87)\
**Post date:** [June 20, 2006, 4:26pm UTC](https://community.unix.com/t/while-loop-problems/162663/1 "2006-06-20T16:26:20Z")

</div>

Here it wont terminate unless i take the not of my statement

#!/bin/bash  
grabXML  
parseXML  
TAIL=5  
#"$(cat dailyCasLog | tail -n 1)"  
COUNT=200  
LINE=5  
#"$(cat dailyCasLog | head -n $COUNT | tail -n 1)"  
echo $TAIL  
echo $LINE  
while ($LINE!=)  
do  
#$LINE"\>\>currentLine

folderMaker

#moveBackup  
#ftp -v -n "$LINE"  
#user "" ""  
#cd PATH to backup  
#get the files  
#bye  
COUNT=$(expr $COUNT + 1)  
echo $COUNT

echo $LINE y  
echo $TAIL y  
LINE="$(cat dailyCasLog|head -n $COUNT | tail -n 1)"  
done  
exit 0

itll just continue to loop forever
