Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ??=include<stdio.h>
- ??=include<string.h>
- ??=include<stdlib.h>
- ??=include<ctype.h>
- ??=define __F__ "contactlist.dat"
- ??=define xvfz printf
- ??=define fxvfz fprintf
- ??=define fzvx if
- ??=define zfvx else
- ??=define vzxf while
- ??=define zxfv do
- typedef int f;
- typedef char z;
- f num_rec = 0;
- f is_saved = 0;
- enum{zoo=31,coo=415,boo=9,woo=26,foo=99,ggg=98,doo=1,moo= 0,_=256};
- struct _z{z firstName??(zoo:>; z lastName??(zoo:>; z address??(coo:>; z postalCode??(boo:>; z phoneNumber??(woo:>;
- struct _z *next;};
- typedef struct _z __Z;
- void Menu(void);
- void Help(void);
- void Add__z(__Z**, __Z**);
- void Display__zs(__Z**);
- void __zSearch(__Z**);
- void Save__zs(__Z**, FILE *);
- void Load__zs(__Z**, __Z**, FILE *);
- void Delete__z(__Z**);
- f isValidNum(z ??(:>, f);
- void FormatNum(z ??(:>, f);
- void WordCap(z ??(:>, f);
- int isValidNum(char Number??(:>, int num_t)
- {
- int i;
- char errMsg??(:> = "There is an error in your number formating.";
- switch(num_t)
- {
- // If we have a phone number, we just check the length
- case 98:
- if(strlen(Number) > 12)
- {
- xvfz("%s\n", errMsg);
- return moo;
- }
- break;
- case 99:
- if(strlen(Number) > 7)
- {
- xvfz("%s\n", errMsg);
- return moo;
- }
- for(i = 0; i < 6; ++i)
- {
- if(i % 2 == 0)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement