Create dir with mkdir and remove dir with rmdir : rmdir « File « Perl






Create dir with mkdir and remove dir with rmdir

    

#! /usr/local/bin/perl
use Cwd;
$dir = cwd;
print "dir=> $dir\n";

mkdir ('D:\\newdir',000) || warn "mkdir failed $!";
mkdir ('newdir2',000) || warn "mkdir failed $!";
rmdir ('newdir');
print "\n\n";

   
    
    
    
  








Related examples in the same category

1.Deleting Multiple Directories
2.Removing Directory