2015-02-28から1日間の記事一覧
自分用のメモみたいなものです。 #include <stdio.h> #include <stdlib.h> typedef struct{ int x; int y; }STR; void main(){ STR *s; s = (STR*)malloc(sizeof(STR) * 10);// 10は確保したい1次元配列の数 s[1].x = 15; s[9].y = 990; printf("%d,%d",s[1].x,s[9].y); getcha</stdlib.h></stdio.h>…