09cau truc - 1 C u trc anhtt@it-hut.edu.vn Khi ni m c u trc...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: 1 C u trc anhtt@it-hut.edu.vn Khi ni m c u trc Th c t chng ta th ng thao tc v i cc th c th lgic bao g m m t s thng tin i theo nhm V d , s ph c bao g m gi tr ph n th c v o, b n ghi mt sinh vin ch a thng tin v tn, im thi, v.v M i th c th nh th ny c c u t o t nhi u bi n, nh ng c th qu n l nh m t n v lgic M t c u trc ( struct ) l m t t p h p c a m t s bi n khc ki u d li u m c ng gi vo m t kh i h p nh t M t khai bo c u trc cho php nh m t ki u d li u ph c h p cho cc bi n ki u c u trc Tn c a cc bi n trong m t c u trc cn c g i l tr ng c u trc Khai bo c u trc struct complex { int real; int img; } ; struct studentRec { char name[80]; int mark; } ; Khai bo tn c a c u trc Cc tr ng c a c u trc ng qun d u ; sau khai bo c u trc Khai bo ny m i ch t o ki u c a c u trc ch ch a c bi n Khai bo bi n c u trc t o m t c u trc trong b nh my tnh, ta c n khai bo m t bi n c u trc nh sau struct complex num; struct studentRec john; Tn ki u c u trc Tn c a bi n K t h p khai bo C th...
View Full Document

Page1 / 3

09cau truc - 1 C u trc anhtt@it-hut.edu.vn Khi ni m c u trc...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online