in reply to "/" with directory in an array

I am not seeing that on my machine

#!/usr/bin/perl -w while(<DATA>){ @array = split '/'; print $array[0],$/; } __DATA__ C:\Documents and Settings\Claire\Desktop\ /LOG:fgf /L /XF doc /W:3 /R: +10 /COPY:dtao /FP

Output

C:\Documents and Settings\Claire\Desktop\

I modified your IN to DATA but it should not cause any issues. Actually i tested this code using the contents inside command.txt and i got the same output

Can you print out the entire line from the file before you split it? like  print;

Also just so that you know split's first arg is a regular exp

I would have written  split /\//

-SK