I'm a beginner in perl and this is my code.
@var1=split (/\\/ , $var);
print "$var1 \n";
The output should be:
But i receive C:Program Filestesttest2 as output. So anyone can help me to spilt and show only C: as output.