How to create folder (directory) on disk in C

2 Answers

0 votes
#include <stdio.h>
#include <unistd.h>
   
int main(int argc, char **argv) 
{ 
    mkdir("test_dir");
        
    return 0;
}
   
/*
  
run:
   
d:\c_examples\Debug\test_dir\

*/

 



answered Sep 28, 2015 by avibootz
0 votes
#include <stdio.h>
#include <unistd.h>
   
int main(int argc, char **argv) 
{ 
    mkdir("d:\\test_dir");
        
    return 0;
}
   
/*
  
run:
   
d:\test_dir\

*/

 



answered Sep 28, 2015 by avibootz

Related questions

3 answers 585 views
1 answer 294 views
294 views asked Jul 2, 2020 by avibootz
1 answer 288 views
288 views asked Sep 29, 2015 by avibootz
1 answer 277 views
2 answers 453 views
1 answer 324 views
1 answer 312 views
312 views asked Aug 2, 2018 by avibootz
...