First, that code won't compile. You have an unmatched right curly bracket.
Do you get any warnings? I get a couple "Use of uninitialized value" warnings. Hint: add a few print statements. I don't think the value of $_ is what you think it is.
I'm not sure why you need to declare $cut outside the scope of the loop. If there is a reason for doing it that way, it's not evident from the code you posted.
Finally, you split the line into @words, but you only test one word for vowels. You'll need to loop over each element of @words if you want to test every word on the line.
I hope this gives you a starting point. It sounds a bit like homework so I tried to err on the side of hints rather than handing you a solution outright.
In reply to Re: Passing a $Scaler into a while loop...
by bobf
in thread Passing a $Scaler into a while loop...
by chinamox
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |