I have a basic code where I can copy an array without problems. But when I introduce another kind of array, a more advanced variant which I think is called a dynamic array. Then my program crashes every time.
What am I doing wrong? What have I misunderstood?
Array tutorial: C Code Listing 7 - Array tutorial = [ Works ]
int i, j;
for(i=0; i<4; i++)
for(j=0; j<4; j++)
Improved code 1: = [ It still Works ]
xnN0TJ17 - Pastebin.com
Improved code 2: = [ It still Works ]
GCCALmpP - Pastebin.com
Improved code 3: = [ FAILED ]
When I uncomment the /* Copy array */ code then the program doesn't work anymore.
Why is it happening at this location? What am I doing wrong? What have I misunderstood?
DsQpH8AX - Pastebin.com