Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Question about "Sub memcpy ..."
#4
Yes, memcpy() is a C function:

Code: (Select All)

//memcpy(), C-Befehlsbibliothek S. 323
//12. Juli 2023

#include <stdio.h>
#include <stdlib.h>
#include <string.h>

#define GROESSE 50

int main(void)
{
char puffer1[GROESSE], puffer2[GROESSE];

strcpy(puffer1, "Das ist ein Test!");
printf("\nPuffer1: ");
printf(puffer1);

//Inhalt von P1 nach P2 kopieren
memcpy(puffer2, puffer1, GROESSE);
printf("\n\nKopiert nach Puffer2: ");
printf (puffer2);

return(0);
}
Reply


Messages In This Thread
Question about "Sub memcpy ..." - by Kernelpanic - 07-12-2024, 05:26 PM
RE: Question about "Sub memcpy ..." - by Pete - 07-12-2024, 05:36 PM
RE: Question about "Sub memcpy ..." - by Kernelpanic - 07-12-2024, 06:32 PM
RE: Question about "Sub memcpy ..." - by SMcNeill - 07-12-2024, 06:50 PM



Users browsing this thread: 4 Guest(s)