回答編集履歴

2

不要行削除

2022/06/14 10:15

投稿

shiracamus
shiracamus

スコア5406

test CHANGED
@@ -1,6 +1,5 @@
1
1
  > ```c
2
2
  > Gdash = (int **)malloc(sizeof(int)*(8-x));
3
- > Gdash[i] = (int *)malloc(sizeof(int)*(8-x));
4
3
  > ```
5
4
 
6
5
  ポインタなのにint分のサイズしか確保してないですよ。

1

コードブロックに言語指定

2022/06/14 10:13

投稿

shiracamus
shiracamus

スコア5406

test CHANGED
@@ -1,8 +1,7 @@
1
- >
1
+ > ```c
2
- ```
3
- Gdash = (int **)malloc(sizeof(int)*(8-x));
2
+ > Gdash = (int **)malloc(sizeof(int)*(8-x));
4
- Gdash[i] = (int *)malloc(sizeof(int)*(8-x));
3
+ > Gdash[i] = (int *)malloc(sizeof(int)*(8-x));
5
- ```
4
+ > ```
6
5
 
7
6
  ポインタなのにint分のサイズしか確保してないですよ。
8
7