[try Beta version]
Not logged in

 
Pointer table.

Sep 9, 2015 at 3:43pm
I'm trying to get this program to work, I'm having pointer crashes as soon as the program hits line 62 on the second iteration, I think I have some how lost the array information, any suggestions?



http://pastebin.com/DjPMLS2W


Table : http://i.imgur.com/kdW6t73.png
Last edited on Sep 9, 2015 at 5:16pm
Sep 9, 2015 at 5:14pm
You are passing your parameters by copy, any change in them would be local to the function.


`s' and `t' should be pointing to the same place, ¿why is their type different?
Sep 9, 2015 at 5:19pm
I thought if you had

1
2
3
4
5
6
7
8
 
int ***a = new int**;
*a = new int*;
**a = new int;
***a = 18

int *c = **a;


Wouldn't that make c point to the int stored in ***a?
Sep 9, 2015 at 6:50pm
¿so?
Sep 9, 2015 at 7:27pm
So wouldn't I would need to point t to the second level of indirection of s, so wouldn't I need to point t to the base level of s?
Last edited on Sep 9, 2015 at 7:29pm
Topic archived. No new replies allowed.