שאלה קטנה על struct בשפת c;
מדוע ההקצאה שביצעתי לא עובדת (הוא רושם שיש typecasting מvoid* לstruct monom ) ?
מדוע ההקצאה שביצעתי לא עובדת (הוא רושם שיש typecasting מvoid* לstruct monom ) ?
typedef struct MONOM{ int mekadem; int power; }monom; void main(void) { monom first; first = (monom) malloc(sizeof(monom)); if(first == NULL) { printf("failed to allocate memory! bye bye..."); exit(1); } }