C / string.h / strncpy
memchr, memcmp, memcpy, memmove, memset, strcat, strchr, strcmp, strcoll, strcpy, strcspn, strerror, strlen, strncat, strncmp, » strncpy, strpbrk, strrchr, strspn, strstr, strtok, strxfrm,
Funcion: strncpy()
Sintaxis:
char *strncpy(char *s1, const char *s2, size_t n);

Descripcion: Copia no más de n caracteres (caracteres posteriores al carácter nulo no son copiados) de la cadena apuntada por s2 a la cadena apuntada por s1.


Ejemplo:
#include <stdio.h>
#include <string.h>
 
int main()
{
   char s2[8] = "abcdefg";
   char s1[8];
 
   strncpy( s1, s2, 3 );
   printf( "s2=%s\n", s2 );
   printf( "s1=%s\n", s1 );
 
   return 0;
}

Librerias C

Librerias ANSI C
   string.hcstring
   math.hcmath
   stdio.hcstdio
   time.hctime
   stdlib.hcstdlib
   ctype.hcctype
   locale.hclocale
   signal.hcsignal
   setjmp.hcsetjmp

Librerias Borland
   conio.h
   graphics.h