Download
dasl 130 c programming course n.
Skip this Video
Loading SlideShow in 5 Seconds..
DASL 130 – C Programming Course PowerPoint Presentation
Download Presentation
DASL 130 – C Programming Course

DASL 130 – C Programming Course

108 Vues Download Presentation
Télécharger la présentation

DASL 130 – C Programming Course

- - - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript

  1. DASL 130 – C Programming Course Lecture 5

  2. Structures struct name{ type name; type2 name2; } instance_name = {name_val, name2_val};

  3. Struct Example struct point{ int x; int y; } ; void move_it(struct point *source, struct point* dest){ source->x = dest->x; source->y = dest->y; }

  4. Struct Example int main() { struct point location = {2, 3}; struct point move_to = {-1, -1}; move_it(location, move_to); }

  5. typedef typedef oldtypename newtypename; typedef struct newtypename{ struct contents; } newtypename; newtypename varname = value;