home *** CD-ROM | disk | FTP | other *** search
/ C by Discovery (4th Edition) / C_By_Discovery_4th_Edition.tar / C_By_Discovery_4th_Edition / CH_07 / 423.jpg < prev    next >
Joint Photographic Experts Group Image  |  2013-12-21  |  534KB  |  2550x3300
Labels: binder | book | crt screen | daybook | poster | reckoner
OCR: Unions Example 7-10 unions.c uni suo the two one of Synops i Accepts input of and displays informa t ion for one empl loyee uctures track union Obiective demonstrate use of of uni enum ion. types to keep may be the contents nters Include Files mem- #include <stdio. h> pointer #incl lude <stdl ib.h> ollow Constant Definiti ions #defi ine NAME LGTH #def ine SSN LGTH #def .ne BUF LGTH 80 rate Type Descr ipt ions enum paytype hourly, salarieo Note un ion rate Note double per hour; int per week; pres- ts of struct empl loyee char name (NAME LGTH] char ssn SSN LGTH enum paytype payty ype; Note 3 the un: .on rate payrate isi Funct: ion Protot ypes type void reademp struct loyee *emptr PRECONDITION: emptr conta ins the address of struct empl loyee POSTCONDITION: Accepts input informa ition from th ...