e c++
getline() tambien sierve para string (es mas recomendable usar string que char en esta funcion)...
en c-ansi
-   
- #include <stdio.h> 
- #include <stdlib.h> 
-   
- char *readLine(FILE *file) { 
-     char *- line  = (char*)malloc(1);
 
-     size_t size = 0; 
-   
-     while ((- line [- size ] = getchar()) != '\n')
 
-         line  = (char*)realloc(- line , ++- size  + 1);
-   
-     line[size] = '\0'; 
-   
-     return line; 
- } 
-   
- int main() {     // ============== 
-     char cmd[512]; 
-     char *path; //  MAX_PATH = 256 
-   
-     path = readLine(stdin); //  leemos una linea desde el buffer de entrada del teclado 
-     sprintf(- cmd , "mkdir \"%s\"",-  path ); //  construimos la cadena por ejemplo: mkdir "c:\Hola Mundo desde C-ANSI"
 
-   
-     return EXIT_SUCCESS; 
- } 
-   
-   
Dulces Lunas!¡.