SlideShare a Scribd company logo
1 of 8
#include<stdio.h><br />    #include<conio.h><br />    #include<dos.h><br />    #include<string.h><br />    void main()<br />    {<br />    int iCh1,iInc;<br />    e:<br />    clrscr();<br />    /* To Display Main menu */<br />    gotoxy(26,40);<br />    textcolor(9);<br />    cprintf(quot;
SOFTWARE ENGINEERING PROJECTquot;
);<br />    gotoxy(32,44);<br />    textcolor(19);<br />    cprintf(quot;
BATCH-1(2006-07)quot;
);<br />    gotoxy(23,42);<br />    cprintf(quot;
ZOO MANAGEMENT SYSTEM ( ZMS-2007)quot;
);<br />    gotoxy(8,45);<br />    textcolor(9);<br />    /* To Dispaly date and time */<br />    cprintf(quot;
DATE : %s quot;
,__DATE__);<br />    gotoxy(55,45);<br />    cprintf(quot;
TIME : %s quot;
,__TIME__);<br />    for(iInc=0;iInc<=30;iInc++)<br />    {<br />    gotoxy(20,iInc);<br />    textcolor(7);<br />    cprintf(quot;
-quot;
);<br />    }<br />    for(iInc=0;iInc<80;iInc++)<br />    {<br />    gotoxy(iInc,30);<br />    textcolor(7);<br />    cprintf(quot;
|quot;
);<br />    }<br />    gotoxy(30,8);<br />    textcolor(9);<br />    /* Main menu */<br />    cprintf(quot;
ZOO MANAGEMENT SYSTEM (ZMS-2007)quot;
);<br />    gotoxy(30,10);<br />    textcolor(19);<br />    cprintf(quot;
1.ANIMALquot;
);<br />    gotoxy(30,12);<br />    cprintf(quot;
2.BIRDquot;
);<br />    gotoxy(30,14);<br />    cprintf(quot;
3.EXITquot;
);<br />    gotoxy(30,18);<br />    textcolor(9);<br />    cprintf(quot;
ENTER YOUR CHOICE:quot;
);<br />    scanf(quot;
%dquot;
,&iCh1);<br />    if<br />    (iCh1==3)<br />    {<br />    /* To exit from the system */<br />    gotoxy(30,28);<br />    textcolor(4);<br />    cprintf(quot;
SYSTEM SHUTTING DOWNquot;
);<br />    sleep(3);<br />    gotoxy(26,40);<br />    printf(quot;
SOFTWARE ENGINEERING PROJECTquot;
);<br />    gotoxy(8,42);<br />    printf(quot;
ZOO MANAGEMENT SYSTEM ( ZMS-2007)quot;
);<br />    gotoxy(8,45);<br />    printf(quot;
DATE : %s quot;
,__DATE__);<br />    gotoxy(55,45);<br />    printf(quot;
TIME : %s quot;
,__TIME__);<br />    exit(0);<br />    }<br />    else{<br />    /* Declarations of Variables */<br />    FILE *fp,*ft;<br />    char cAns,cChoice;<br />    struct zoo<br />    {<br />    char offspr[2],anim_history[50],an_name[30],keeper_nm[20],cellid[4],an_sex[2];<br />    int anim_age,offno;<br />    float wt,offrat,inbreed,food_s,food_c;<br />    };<br />    struct zoo e;<br />    char cell_id[4];<br />    int iF=0,iC=0,iF1=0;<br />    long int lRecsize;<br />    fp=fopen(quot;
zm.datquot;
,quot;
rb+quot;
);<br />    if(fp==NULL)<br />    {<br />    fp=fopen(quot;
m.datquot;
,quot;
wb+quot;
);<br />    if(fp==NULL)<br />    {<br />    puts(quot;
Cannot Open filequot;
);<br />    exit();<br />    }<br />    }<br />    lRecsize=sizeof(e);<br />    while(1)<br />    {<br />    clrscr();<br />    textcolor(4);<br />    if(iCh1==1) {<br />    gotoxy(30,8);<br />    textcolor(4);<br />    cprintf(quot;
ANIMAL MENUquot;
); }<br />    else if(iCh1==2) {<br />    gotoxy(30,8);<br />    textcolor(4);<br />    cprintf(quot;
BIRD MENUquot;
); }<br />    gotoxy(26,40);<br />    textcolor(4);<br />    cprintf(quot;
SOFTWARE ENGINEERING PROJECTquot;
);<br />    gotoxy(32,44);<br />    textcolor(19);<br />    cprintf(quot;
BATCH-1(2006-07)quot;
);<br />    gotoxy(23,42);<br />    textcolor(19);<br />    cprintf(quot;
ZOO MANAGEMENT SYSTEM ( ZMS-2007 )quot;
);<br />    gotoxy(8,45);<br />    textcolor(4);<br />    cprintf(quot;
DATE : %s quot;
,__DATE__);<br />    gotoxy(55,45);<br />    cprintf(quot;
TIME : %s quot;
,__TIME__);<br />    for(iInc=0;iInc<=30;iInc++)<br />    {<br />    gotoxy(20,iInc);<br />    textcolor(7);<br />    cprintf(quot;
-quot;
);<br />    }<br />    for(iInc=0;iInc<=80;iInc++)<br />    {<br />    gotoxy(iInc,30);<br />    textcolor(7);<br />    cprintf(quot;
|quot;
);<br />    }<br />    gotoxy(30,10);<br />    textcolor(19);<br />    cprintf(quot;
1.ADD quot;
);<br />    gotoxy(30,12);<br />    cprintf(quot;
2.DISPLAYquot;
);<br />    gotoxy(30,14);<br />    cprintf(quot;
3.MODIFYquot;
);<br />    gotoxy(30,16);<br />    cprintf(quot;
4.DELETEquot;
);<br />    gotoxy(30,18);<br />    cprintf(quot;
5.EXITquot;
);<br />    gotoxy(30,20);<br />    textcolor(4);<br />    cprintf(quot;
SELECT YOUR OPTION: quot;
);<br />    fflush(stdin);<br />    cChoice=getche();<br />    clrscr();<br />    gotoxy(25,8);<br />    textcolor(5);<br />    switch(cChoice)<br />    {<br />    case '1':<br />    //To add a record<br />    w:<br />    printf(quot;
ENTER CELL ID( 3 DIGIT NO.): quot;
);<br />    scanf(quot;
%squot;
,cell_id);<br />    rewind(fp);<br />    //Checking for unique id<br />    while(fread(&e,lRecsize,1,fp)==1)<br />    {<br />    if(strcmp(e.cellid,cell_id)==0)<br />    {<br />    iF=1;<br />    printf(quot;
THE ID ALREADY EXISTSquot;
);<br />    goto w;<br />    }}<br />    if(iF==0||fread(&e,lRecsize,1,fp)==0)<br />    {<br />    fseek (fp,0,SEEK_END);<br />    strcpy(e.cellid,cell_id);<br />    a3:<br />    printf(quot;
ENTER ANIMAL NAME: quot;
);<br />    scanf(quot;
%squot;
,e.an_name);<br />    if(strlen(e.an_name)>30||strlen(e.an_name)<3)<br />    goto a3;<br />    printf(quot;
ENTER ZOO KEEPER NAME: quot;
);<br />    scanf(quot;
%squot;
,e.keeper_nm); <br />    p:<br />    printf(quot;
ENTER SEX [M/F]: quot;
);<br />    scanf(quot;
%squot;
,e.an_sex);<br />    if(strlen(e.an_sex)>1)<br />    goto p;<br />    f:<br />    printf(quot;
ENTER AGE : quot;
);<br />    scanf(quot;
%dquot;
,&e.anim_age);<br />    if(e.anim_age<0||e.anim_age>100)<br />    goto f; <br />    a5:<br />    printf(quot;
OFFSPRING [P/A]:quot;
);<br />    scanf(quot;
%squot;
,&e.offspr);<br />    if(strlen(e.offspr)>1)<br />    goto a5;<br />    printf(quot;
ENTER NO. OF OFFSPRING: quot;
);<br />    scanf(quot;
%dquot;
,&e.offno);<br />    printf(quot;
FOOD SUPPLIED( IN KG): quot;
);<br />    scanf(quot;
%fquot;
,&e.food_s);<br />    printf(quot;
FOOD CONSUMED( IN KG): quot;
);<br />    scanf(quot;
%fquot;
,&e.food_c);<br />    a2:<br />    printf(quot;
ANIMAL DETAILS(IF ANY)(Don't leave space,use '_'): quot;
);<br />    scanf(quot;
%squot;
,e.anim_history);<br />    if(strlen(e.anim_history)>50)<br />    goto a2;<br />    fwrite(&e,lRecsize,1,fp);<br />    /*Flushes a stream On success returns 0 , On error returns EOF */<br />    fflush(stdin);<br />    }<br />    break;<br />    case '2':<br />    //Searching and displaying all the infor<br />    //     mation by id<br />    textcolor(7);<br />    printf(quot;
ENTER CELL ID: quot;
);<br />    scanf(quot;
%squot;
,cell_id);<br />    rewind(fp);<br />    while(fread(&e,lRecsize,1,fp)!=0)<br />    {<br />    if(strcmp(e.cellid,cell_id)==0)<br />    { iC=1;<br />    clrscr();<br />    //Display according to Main menu<br />    gotoxy(0,20);<br />    //ANIMAL<br />    if(iCh1==1){<br />    printf(quot;
DETAILS OF THE ANIMAL:%squot;
,strupr(e.an_name));<br />    printf(quot;
_____________________________________________________________________quot;
);<br />    printf(quot;
 NAME : %s CELL ID : %s ZOO KEEPER NAME : %s SEX: %s AGE : %d  OFFSPRING: %s OFFSPRING NO. : %d OFFSPRING RATIO : %f INBREED RATIO : %f FOOD SUPPLIED : %f FOOD CONSUMED : %f ANIMAL DETAILS: %squot;
,strupr(e.an_name),strupr(e.cellid),strupr(e.keeper_nm),strupr(e.an_sex),e.anim_age,strupr(e.offspr),e.offno,(e.offno/13.33*6.2),(e.offno*12.66/17.3574),e.food_s,e.food_c,strupr(e.anim_history));<br />    printf(quot;
_____________________________________________________________________quot;
);<br />    getch(); }<br />    //BIRD<br />    else if(iCh1==2){<br />    printf(quot;
DETAILS OF BIRD:%squot;
,strupr(e.an_name));<br />    printf(quot;
_____________________________________________________________________quot;
);<br />    printf(quot;
 NAME : %s CELL ID : %s ZOO KEEPER NAME : %s AGE: %d SEX : %s  OFFSPRING: %s OFFSPRING NO. : %d OFFSPRING RATIO : %f INBREED RATIO : %f FOOD SUPPLIED : %f FOOD CONSUMED : %f ANIMAL DETAILS: %squot;
,strupr(e.an_name),strupr(e.cellid),strupr(e.keeper_nm),e.anim_age,strupr(e.an_sex),strupr(e.offspr),e.offno,(e.offno/13.33*6.2),(e.offno*12.66/17.3574),e.food_s,e.food_c,strupr(e.anim_history));<br />    printf(quot;
_____________________________________________________________________quot;
);<br />    getch(); }<br />    }<br />    }<br />    if(iC==0)<br />    {<br />    printf(quot;
RECORD DOESN'T EXISTS..quot;
);<br />    getch();<br />    }iC=0;<br />    break;<br />    case '3':<br />    //Searching and modifying Records by id<br />    cAns='y';<br />    while(cAns=='y')<br />    {<br />    printf(quot;
ENTER CELL ID: quot;
);<br />    scanf(quot;
%squot;
,cell_id);<br />    rewind(fp);<br />    while(fread(&e,lRecsize,1,fp)==1)<br />    {<br />    if(strcmp(e.cellid,cell_id)==0)<br />    {<br />    b:<br />    printf(quot;
ENTER ANIMAL NAME: %s : quot;
,strupr(e.an_name));<br />    scanf(quot;
%squot;
,e.an_name);<br />    if(strlen(e.an_name)>20||strlen(e.an_name)<3)<br />    goto b;<br />    b1:<br />    printf(quot;
 ENTER SEX : %s : quot;
,strupr(e.an_sex));<br />    scanf(quot;
%squot;
,e.an_sex);<br />    if(strlen(e.an_sex)>1)<br />    goto b1;<br />    r:<br />    printf(quot;
 ENTER AGE: %d : quot;
 ,e.anim_age);<br />    scanf(quot;
%dquot;
,&e.anim_age);<br />    if(e.anim_age<1||e.anim_age>100)<br />    goto r;<br />    ad:<br />    printf(quot;
 OFFSPRING : %s : quot;
,strupr(e.offspr));<br />    scanf(quot;
%squot;
,e.offspr);<br />    if(strlen(e.offspr)<1)<br />    goto ad;<br />    printf(quot;
 ENTER NO. OF OFFSPRING: %d :quot;
,e.offno);<br />    scanf(quot;
%dquot;
,&e.offno);<br />    printf(quot;
 ENTER FOOD SUPPLIED(IN KG): %f :quot;
,e.food_s);<br />    scanf(quot;
%fquot;
,&e.food_s);<br />    printf(quot;
FOOD CONSUMED( IN KG): quot;
);<br />    scanf(quot;
%fquot;
,&e.food_c);<br />    b5:<br />    printf(quot;
ANIMAL DETAILS( IF ANY )(Dont leave space,use'_'instead)': %s : quot;
,e.anim_history);<br />    scanf(quot;
%squot;
,e.anim_history);<br />    if(strlen(e.anim_history)>50)<br />    goto b5;<br />    fseek(fp,-lRecsize,SEEK_CUR); //Repositions the file pointer of a stream<br />    fwrite(&e,lRecsize,1,fp);<br />    printf(quot;
RECORD MODIFIED quot;
);<br />    break;<br />    }<br />    }<br />    printf(quot;
DO U WANT TO MODIFY ANY RECORD[y/n]quot;
);<br />    /*Flushes a stream On success returns 0 , On error returns EOF */<br />    fflush(stdin);<br />    cAns=getche();<br />    }<br />    break;<br />    case '4':<br />    //Searching and deleting records by id<br />    cAns='y';<br />    while(cAns=='y')<br />    {<br />    printf(quot;
ENTER CELL ID TO DELETE RECORD : quot;
);<br />    scanf(quot;
%squot;
,cell_id);<br />    ft=fopen(quot;
temp.datquot;
,quot;
wbquot;
);<br />    rewind(fp); //Repositions file pointer to stream's beginning<br />    while(fread(&e,lRecsize,1,fp)!=0)<br />    {<br />    if(strcmp(e.cellid,cell_id)!=0) {<br />    fwrite(&e,lRecsize,1,ft);<br />    }<br />    else {<br />    iF1=1;<br />    printf(quot;
 RECORD DELETED SUCCESSFULLYquot;
);<br />    }<br />    }<br />    if(iF1!=1){iF1=0;<br />    printf(quot;
 NO SUCH RECORD FOUNDquot;
);}<br />    fclose(fp);<br />    fclose(ft);<br />    remove(quot;
zm.datquot;
);<br />    rename(quot;
temp.datquot;
,quot;
zm.datquot;
);<br />    fp=fopen(quot;
zm.datquot;
,quot;
rb+quot;
);<br />    printf(quot;
DO U WANT TO DELETE ANOTHER RECORD[y/n]quot;
);<br />    fflush(stdin);<br />    cAns=getche();<br />    }<br />    break;<br />    case '5':<br />    fclose(fp);<br />    goto e;<br />    }<br />    }<br />    }<br />    }<br />
Zoo management  adri jovin
Zoo management  adri jovin
Zoo management  adri jovin
Zoo management  adri jovin
Zoo management  adri jovin
Zoo management  adri jovin
Zoo management  adri jovin

More Related Content

What's hot

6 things about perl 6
6 things about perl 66 things about perl 6
6 things about perl 6brian d foy
 
GDG DevFest Kyoto 2014 これからのGoの話をしよう
GDG DevFest Kyoto 2014 これからのGoの話をしようGDG DevFest Kyoto 2014 これからのGoの話をしよう
GDG DevFest Kyoto 2014 これからのGoの話をしようSatoshi Noda
 
openFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートII
openFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートIIopenFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートII
openFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートIIAtsushi Tadokoro
 
24 bit wallace_tree_multiplier
24 bit wallace_tree_multiplier24 bit wallace_tree_multiplier
24 bit wallace_tree_multiplierAnkur Vasava
 
Top 10 php classic traps DPC 2020
Top 10 php classic traps DPC 2020Top 10 php classic traps DPC 2020
Top 10 php classic traps DPC 2020Damien Seguy
 
Amazon VPC and Amazon EC2
Amazon VPC and Amazon EC2Amazon VPC and Amazon EC2
Amazon VPC and Amazon EC2Daiki Mori
 
FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6
FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6
FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6FrontDays
 
Hangman Game Programming in C (coding)
Hangman Game Programming in C (coding)Hangman Game Programming in C (coding)
Hangman Game Programming in C (coding)hasan0812
 
(Meta 2.3) figura de auto con simbolos dev c++
(Meta 2.3) figura de auto con simbolos dev c++ (Meta 2.3) figura de auto con simbolos dev c++
(Meta 2.3) figura de auto con simbolos dev c++ Eli Diaz
 
"Internationalisation with PHP and Intl" source code
"Internationalisation with PHP and Intl" source code"Internationalisation with PHP and Intl" source code
"Internationalisation with PHP and Intl" source codeDaniel_Rhodes
 
One definition rule - что это такое, и как с этим жить
One definition rule - что это такое, и как с этим житьOne definition rule - что это такое, и как с этим жить
One definition rule - что это такое, и как с этим житьPlatonov Sergey
 
The Ring programming language version 1.5.2 book - Part 8 of 181
The Ring programming language version 1.5.2 book - Part 8 of 181The Ring programming language version 1.5.2 book - Part 8 of 181
The Ring programming language version 1.5.2 book - Part 8 of 181Mahmoud Samir Fayed
 
Perl Bag of Tricks - Baltimore Perl mongers
Perl Bag of Tricks  -  Baltimore Perl mongersPerl Bag of Tricks  -  Baltimore Perl mongers
Perl Bag of Tricks - Baltimore Perl mongersbrian d foy
 
LAMP_TRAINING_SESSION_7
LAMP_TRAINING_SESSION_7LAMP_TRAINING_SESSION_7
LAMP_TRAINING_SESSION_7umapst
 
Project fast food automaton
Project fast food automatonProject fast food automaton
Project fast food automatonvarun arora
 

What's hot (20)

6 things about perl 6
6 things about perl 66 things about perl 6
6 things about perl 6
 
GDG DevFest Kyoto 2014 これからのGoの話をしよう
GDG DevFest Kyoto 2014 これからのGoの話をしようGDG DevFest Kyoto 2014 これからのGoの話をしよう
GDG DevFest Kyoto 2014 これからのGoの話をしよう
 
openFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートII
openFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートIIopenFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートII
openFrameworks – 関数・クラス、オブジェクト指向プログラミング導入 - 多摩美メディアアートII
 
36 gotas de-sabiduria
36 gotas de-sabiduria36 gotas de-sabiduria
36 gotas de-sabiduria
 
24 bit wallace_tree_multiplier
24 bit wallace_tree_multiplier24 bit wallace_tree_multiplier
24 bit wallace_tree_multiplier
 
Of class3
Of class3Of class3
Of class3
 
Yg byev2e
Yg byev2eYg byev2e
Yg byev2e
 
Top 10 php classic traps DPC 2020
Top 10 php classic traps DPC 2020Top 10 php classic traps DPC 2020
Top 10 php classic traps DPC 2020
 
Amazon VPC and Amazon EC2
Amazon VPC and Amazon EC2Amazon VPC and Amazon EC2
Amazon VPC and Amazon EC2
 
FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6
FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6
FrontDays #3. Иван Федяев, Эволюция JavaScript. Обзор нововведений ECMAScript 6
 
Hangman Game Programming in C (coding)
Hangman Game Programming in C (coding)Hangman Game Programming in C (coding)
Hangman Game Programming in C (coding)
 
(Meta 2.3) figura de auto con simbolos dev c++
(Meta 2.3) figura de auto con simbolos dev c++ (Meta 2.3) figura de auto con simbolos dev c++
(Meta 2.3) figura de auto con simbolos dev c++
 
"Internationalisation with PHP and Intl" source code
"Internationalisation with PHP and Intl" source code"Internationalisation with PHP and Intl" source code
"Internationalisation with PHP and Intl" source code
 
5 Rmi Print
5  Rmi Print5  Rmi Print
5 Rmi Print
 
Deber base
Deber baseDeber base
Deber base
 
One definition rule - что это такое, и как с этим жить
One definition rule - что это такое, и как с этим житьOne definition rule - что это такое, и как с этим жить
One definition rule - что это такое, и как с этим жить
 
The Ring programming language version 1.5.2 book - Part 8 of 181
The Ring programming language version 1.5.2 book - Part 8 of 181The Ring programming language version 1.5.2 book - Part 8 of 181
The Ring programming language version 1.5.2 book - Part 8 of 181
 
Perl Bag of Tricks - Baltimore Perl mongers
Perl Bag of Tricks  -  Baltimore Perl mongersPerl Bag of Tricks  -  Baltimore Perl mongers
Perl Bag of Tricks - Baltimore Perl mongers
 
LAMP_TRAINING_SESSION_7
LAMP_TRAINING_SESSION_7LAMP_TRAINING_SESSION_7
LAMP_TRAINING_SESSION_7
 
Project fast food automaton
Project fast food automatonProject fast food automaton
Project fast food automaton
 

Similar to Zoo management adri jovin

Dti2143 lab sheet 8
Dti2143 lab sheet 8Dti2143 lab sheet 8
Dti2143 lab sheet 8alish sha
 
Bti1022 lab sheet 8
Bti1022 lab sheet 8Bti1022 lab sheet 8
Bti1022 lab sheet 8alish sha
 
Bti1022 lab sheet 8
Bti1022 lab sheet 8Bti1022 lab sheet 8
Bti1022 lab sheet 8alish sha
 
Network lap pgms 7th semester
Network lap pgms 7th semesterNetwork lap pgms 7th semester
Network lap pgms 7th semesterDOSONKA Group
 
Student teacher database management
Student teacher database managementStudent teacher database management
Student teacher database managementdharmenderlodhi021
 
C basics
C basicsC basics
C basicsMSc CST
 
4 operators, expressions &amp; statements
4  operators, expressions &amp; statements4  operators, expressions &amp; statements
4 operators, expressions &amp; statementsMomenMostafa
 
Compiler Design Lab File
Compiler Design Lab FileCompiler Design Lab File
Compiler Design Lab FileKandarp Tiwari
 
Erlang Introduction Bcberlin3
Erlang Introduction Bcberlin3Erlang Introduction Bcberlin3
Erlang Introduction Bcberlin3guesta3202
 
C programs Set 4
C programs Set 4C programs Set 4
C programs Set 4Koshy Geoji
 
ood evening people. Ive been working on this code that sends a bur.pdf
ood evening people. Ive been working on this code that sends a bur.pdfood evening people. Ive been working on this code that sends a bur.pdf
ood evening people. Ive been working on this code that sends a bur.pdfaroramobiles1
 
¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...
¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...
¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...Software Guru
 
Introduction to Assembly Language
Introduction to Assembly LanguageIntroduction to Assembly Language
Introduction to Assembly LanguageMotaz Saad
 
Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)
Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)
Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)Hari
 
Bti1022 lab sheet 7
Bti1022 lab sheet 7Bti1022 lab sheet 7
Bti1022 lab sheet 7alish sha
 

Similar to Zoo management adri jovin (20)

Dti2143 lab sheet 8
Dti2143 lab sheet 8Dti2143 lab sheet 8
Dti2143 lab sheet 8
 
Bti1022 lab sheet 8
Bti1022 lab sheet 8Bti1022 lab sheet 8
Bti1022 lab sheet 8
 
Bti1022 lab sheet 8
Bti1022 lab sheet 8Bti1022 lab sheet 8
Bti1022 lab sheet 8
 
Network lap pgms 7th semester
Network lap pgms 7th semesterNetwork lap pgms 7th semester
Network lap pgms 7th semester
 
8.1
8.18.1
8.1
 
Lab loop
Lab loopLab loop
Lab loop
 
Student teacher database management
Student teacher database managementStudent teacher database management
Student teacher database management
 
C basics
C basicsC basics
C basics
 
4 operators, expressions &amp; statements
4  operators, expressions &amp; statements4  operators, expressions &amp; statements
4 operators, expressions &amp; statements
 
Compiler Design Lab File
Compiler Design Lab FileCompiler Design Lab File
Compiler Design Lab File
 
Erlang Introduction Bcberlin3
Erlang Introduction Bcberlin3Erlang Introduction Bcberlin3
Erlang Introduction Bcberlin3
 
ภาษา C
ภาษา Cภาษา C
ภาษา C
 
C programs Set 4
C programs Set 4C programs Set 4
C programs Set 4
 
Ch8 file processing
Ch8 file processingCh8 file processing
Ch8 file processing
 
Mauro yaguachi
Mauro yaguachiMauro yaguachi
Mauro yaguachi
 
ood evening people. Ive been working on this code that sends a bur.pdf
ood evening people. Ive been working on this code that sends a bur.pdfood evening people. Ive been working on this code that sends a bur.pdf
ood evening people. Ive been working on this code that sends a bur.pdf
 
¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...
¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...
¡Ups! código inseguro: detección, explotación y mitigación de vulnerabilidade...
 
Introduction to Assembly Language
Introduction to Assembly LanguageIntroduction to Assembly Language
Introduction to Assembly Language
 
Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)
Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)
Source Code of Building Linux IPv6 DNS Server (Complete Sourcecode)
 
Bti1022 lab sheet 7
Bti1022 lab sheet 7Bti1022 lab sheet 7
Bti1022 lab sheet 7
 

More from Adri Jovin

Adri Jovin J J - CV
Adri Jovin J J - CVAdri Jovin J J - CV
Adri Jovin J J - CVAdri Jovin
 
Introduction to Relational Database Management Systems
Introduction to Relational Database Management SystemsIntroduction to Relational Database Management Systems
Introduction to Relational Database Management SystemsAdri Jovin
 
Introduction to ER Diagrams
Introduction to ER DiagramsIntroduction to ER Diagrams
Introduction to ER DiagramsAdri Jovin
 
Introduction to Database Management Systems
Introduction to Database Management SystemsIntroduction to Database Management Systems
Introduction to Database Management SystemsAdri Jovin
 
Neural Networks
Neural NetworksNeural Networks
Neural NetworksAdri Jovin
 
Introduction to Genetic Algorithm
Introduction to Genetic AlgorithmIntroduction to Genetic Algorithm
Introduction to Genetic AlgorithmAdri Jovin
 
Introduction to Fuzzy logic
Introduction to Fuzzy logicIntroduction to Fuzzy logic
Introduction to Fuzzy logicAdri Jovin
 
Introduction to Artificial Neural Networks
Introduction to Artificial Neural NetworksIntroduction to Artificial Neural Networks
Introduction to Artificial Neural NetworksAdri Jovin
 
Introductory Session on Soft Computing
Introductory Session on Soft ComputingIntroductory Session on Soft Computing
Introductory Session on Soft ComputingAdri Jovin
 
Creative Commons
Creative CommonsCreative Commons
Creative CommonsAdri Jovin
 
Image based security
Image based securityImage based security
Image based securityAdri Jovin
 
Blockchain Technologies
Blockchain TechnologiesBlockchain Technologies
Blockchain TechnologiesAdri Jovin
 
Introduction to Cybersecurity
Introduction to CybersecurityIntroduction to Cybersecurity
Introduction to CybersecurityAdri Jovin
 
Advanced Encryption System & Block Cipher Modes of Operations
Advanced Encryption System & Block Cipher Modes of OperationsAdvanced Encryption System & Block Cipher Modes of Operations
Advanced Encryption System & Block Cipher Modes of OperationsAdri Jovin
 
Heartbleed Bug: A case study
Heartbleed Bug: A case studyHeartbleed Bug: A case study
Heartbleed Bug: A case studyAdri Jovin
 
Zoom: Privacy and Security - A case study
Zoom: Privacy and Security - A case studyZoom: Privacy and Security - A case study
Zoom: Privacy and Security - A case studyAdri Jovin
 
Elliptic Curve Cryptography
Elliptic Curve CryptographyElliptic Curve Cryptography
Elliptic Curve CryptographyAdri Jovin
 
El Gamal Cryptosystem
El Gamal CryptosystemEl Gamal Cryptosystem
El Gamal CryptosystemAdri Jovin
 
Data Encryption Standard
Data Encryption StandardData Encryption Standard
Data Encryption StandardAdri Jovin
 
Classical cryptographic techniques, Feistel cipher structure
Classical cryptographic techniques, Feistel cipher structureClassical cryptographic techniques, Feistel cipher structure
Classical cryptographic techniques, Feistel cipher structureAdri Jovin
 

More from Adri Jovin (20)

Adri Jovin J J - CV
Adri Jovin J J - CVAdri Jovin J J - CV
Adri Jovin J J - CV
 
Introduction to Relational Database Management Systems
Introduction to Relational Database Management SystemsIntroduction to Relational Database Management Systems
Introduction to Relational Database Management Systems
 
Introduction to ER Diagrams
Introduction to ER DiagramsIntroduction to ER Diagrams
Introduction to ER Diagrams
 
Introduction to Database Management Systems
Introduction to Database Management SystemsIntroduction to Database Management Systems
Introduction to Database Management Systems
 
Neural Networks
Neural NetworksNeural Networks
Neural Networks
 
Introduction to Genetic Algorithm
Introduction to Genetic AlgorithmIntroduction to Genetic Algorithm
Introduction to Genetic Algorithm
 
Introduction to Fuzzy logic
Introduction to Fuzzy logicIntroduction to Fuzzy logic
Introduction to Fuzzy logic
 
Introduction to Artificial Neural Networks
Introduction to Artificial Neural NetworksIntroduction to Artificial Neural Networks
Introduction to Artificial Neural Networks
 
Introductory Session on Soft Computing
Introductory Session on Soft ComputingIntroductory Session on Soft Computing
Introductory Session on Soft Computing
 
Creative Commons
Creative CommonsCreative Commons
Creative Commons
 
Image based security
Image based securityImage based security
Image based security
 
Blockchain Technologies
Blockchain TechnologiesBlockchain Technologies
Blockchain Technologies
 
Introduction to Cybersecurity
Introduction to CybersecurityIntroduction to Cybersecurity
Introduction to Cybersecurity
 
Advanced Encryption System & Block Cipher Modes of Operations
Advanced Encryption System & Block Cipher Modes of OperationsAdvanced Encryption System & Block Cipher Modes of Operations
Advanced Encryption System & Block Cipher Modes of Operations
 
Heartbleed Bug: A case study
Heartbleed Bug: A case studyHeartbleed Bug: A case study
Heartbleed Bug: A case study
 
Zoom: Privacy and Security - A case study
Zoom: Privacy and Security - A case studyZoom: Privacy and Security - A case study
Zoom: Privacy and Security - A case study
 
Elliptic Curve Cryptography
Elliptic Curve CryptographyElliptic Curve Cryptography
Elliptic Curve Cryptography
 
El Gamal Cryptosystem
El Gamal CryptosystemEl Gamal Cryptosystem
El Gamal Cryptosystem
 
Data Encryption Standard
Data Encryption StandardData Encryption Standard
Data Encryption Standard
 
Classical cryptographic techniques, Feistel cipher structure
Classical cryptographic techniques, Feistel cipher structureClassical cryptographic techniques, Feistel cipher structure
Classical cryptographic techniques, Feistel cipher structure
 

Recently uploaded

MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024The Digital Insurer
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Angeliki Cooney
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Zilliz
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyKhushali Kathiriya
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdfSandro Moreira
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 

Recently uploaded (20)

MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf[BuildWithAI] Introduction to Gemini.pdf
[BuildWithAI] Introduction to Gemini.pdf
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 

Zoo management adri jovin

  • 1. #include<stdio.h><br /> #include<conio.h><br /> #include<dos.h><br /> #include<string.h><br /> void main()<br /> {<br /> int iCh1,iInc;<br /> e:<br /> clrscr();<br /> /* To Display Main menu */<br /> gotoxy(26,40);<br /> textcolor(9);<br /> cprintf(quot; SOFTWARE ENGINEERING PROJECTquot; );<br /> gotoxy(32,44);<br /> textcolor(19);<br /> cprintf(quot; BATCH-1(2006-07)quot; );<br /> gotoxy(23,42);<br /> cprintf(quot; ZOO MANAGEMENT SYSTEM ( ZMS-2007)quot; );<br /> gotoxy(8,45);<br /> textcolor(9);<br /> /* To Dispaly date and time */<br /> cprintf(quot; DATE : %s quot; ,__DATE__);<br /> gotoxy(55,45);<br /> cprintf(quot; TIME : %s quot; ,__TIME__);<br /> for(iInc=0;iInc<=30;iInc++)<br /> {<br /> gotoxy(20,iInc);<br /> textcolor(7);<br /> cprintf(quot; -quot; );<br /> }<br /> for(iInc=0;iInc<80;iInc++)<br /> {<br /> gotoxy(iInc,30);<br /> textcolor(7);<br /> cprintf(quot; |quot; );<br /> }<br /> gotoxy(30,8);<br /> textcolor(9);<br /> /* Main menu */<br /> cprintf(quot; ZOO MANAGEMENT SYSTEM (ZMS-2007)quot; );<br /> gotoxy(30,10);<br /> textcolor(19);<br /> cprintf(quot; 1.ANIMALquot; );<br /> gotoxy(30,12);<br /> cprintf(quot; 2.BIRDquot; );<br /> gotoxy(30,14);<br /> cprintf(quot; 3.EXITquot; );<br /> gotoxy(30,18);<br /> textcolor(9);<br /> cprintf(quot; ENTER YOUR CHOICE:quot; );<br /> scanf(quot; %dquot; ,&iCh1);<br /> if<br /> (iCh1==3)<br /> {<br /> /* To exit from the system */<br /> gotoxy(30,28);<br /> textcolor(4);<br /> cprintf(quot; SYSTEM SHUTTING DOWNquot; );<br /> sleep(3);<br /> gotoxy(26,40);<br /> printf(quot; SOFTWARE ENGINEERING PROJECTquot; );<br /> gotoxy(8,42);<br /> printf(quot; ZOO MANAGEMENT SYSTEM ( ZMS-2007)quot; );<br /> gotoxy(8,45);<br /> printf(quot; DATE : %s quot; ,__DATE__);<br /> gotoxy(55,45);<br /> printf(quot; TIME : %s quot; ,__TIME__);<br /> exit(0);<br /> }<br /> else{<br /> /* Declarations of Variables */<br /> FILE *fp,*ft;<br /> char cAns,cChoice;<br /> struct zoo<br /> {<br /> char offspr[2],anim_history[50],an_name[30],keeper_nm[20],cellid[4],an_sex[2];<br /> int anim_age,offno;<br /> float wt,offrat,inbreed,food_s,food_c;<br /> };<br /> struct zoo e;<br /> char cell_id[4];<br /> int iF=0,iC=0,iF1=0;<br /> long int lRecsize;<br /> fp=fopen(quot; zm.datquot; ,quot; rb+quot; );<br /> if(fp==NULL)<br /> {<br /> fp=fopen(quot; m.datquot; ,quot; wb+quot; );<br /> if(fp==NULL)<br /> {<br /> puts(quot; Cannot Open filequot; );<br /> exit();<br /> }<br /> }<br /> lRecsize=sizeof(e);<br /> while(1)<br /> {<br /> clrscr();<br /> textcolor(4);<br /> if(iCh1==1) {<br /> gotoxy(30,8);<br /> textcolor(4);<br /> cprintf(quot; ANIMAL MENUquot; ); }<br /> else if(iCh1==2) {<br /> gotoxy(30,8);<br /> textcolor(4);<br /> cprintf(quot; BIRD MENUquot; ); }<br /> gotoxy(26,40);<br /> textcolor(4);<br /> cprintf(quot; SOFTWARE ENGINEERING PROJECTquot; );<br /> gotoxy(32,44);<br /> textcolor(19);<br /> cprintf(quot; BATCH-1(2006-07)quot; );<br /> gotoxy(23,42);<br /> textcolor(19);<br /> cprintf(quot; ZOO MANAGEMENT SYSTEM ( ZMS-2007 )quot; );<br /> gotoxy(8,45);<br /> textcolor(4);<br /> cprintf(quot; DATE : %s quot; ,__DATE__);<br /> gotoxy(55,45);<br /> cprintf(quot; TIME : %s quot; ,__TIME__);<br /> for(iInc=0;iInc<=30;iInc++)<br /> {<br /> gotoxy(20,iInc);<br /> textcolor(7);<br /> cprintf(quot; -quot; );<br /> }<br /> for(iInc=0;iInc<=80;iInc++)<br /> {<br /> gotoxy(iInc,30);<br /> textcolor(7);<br /> cprintf(quot; |quot; );<br /> }<br /> gotoxy(30,10);<br /> textcolor(19);<br /> cprintf(quot; 1.ADD quot; );<br /> gotoxy(30,12);<br /> cprintf(quot; 2.DISPLAYquot; );<br /> gotoxy(30,14);<br /> cprintf(quot; 3.MODIFYquot; );<br /> gotoxy(30,16);<br /> cprintf(quot; 4.DELETEquot; );<br /> gotoxy(30,18);<br /> cprintf(quot; 5.EXITquot; );<br /> gotoxy(30,20);<br /> textcolor(4);<br /> cprintf(quot; SELECT YOUR OPTION: quot; );<br /> fflush(stdin);<br /> cChoice=getche();<br /> clrscr();<br /> gotoxy(25,8);<br /> textcolor(5);<br /> switch(cChoice)<br /> {<br /> case '1':<br /> //To add a record<br /> w:<br /> printf(quot; ENTER CELL ID( 3 DIGIT NO.): quot; );<br /> scanf(quot; %squot; ,cell_id);<br /> rewind(fp);<br /> //Checking for unique id<br /> while(fread(&e,lRecsize,1,fp)==1)<br /> {<br /> if(strcmp(e.cellid,cell_id)==0)<br /> {<br /> iF=1;<br /> printf(quot; THE ID ALREADY EXISTSquot; );<br /> goto w;<br /> }}<br /> if(iF==0||fread(&e,lRecsize,1,fp)==0)<br /> {<br /> fseek (fp,0,SEEK_END);<br /> strcpy(e.cellid,cell_id);<br /> a3:<br /> printf(quot; ENTER ANIMAL NAME: quot; );<br /> scanf(quot; %squot; ,e.an_name);<br /> if(strlen(e.an_name)>30||strlen(e.an_name)<3)<br /> goto a3;<br /> printf(quot; ENTER ZOO KEEPER NAME: quot; );<br /> scanf(quot; %squot; ,e.keeper_nm); <br /> p:<br /> printf(quot; ENTER SEX [M/F]: quot; );<br /> scanf(quot; %squot; ,e.an_sex);<br /> if(strlen(e.an_sex)>1)<br /> goto p;<br /> f:<br /> printf(quot; ENTER AGE : quot; );<br /> scanf(quot; %dquot; ,&e.anim_age);<br /> if(e.anim_age<0||e.anim_age>100)<br /> goto f; <br /> a5:<br /> printf(quot; OFFSPRING [P/A]:quot; );<br /> scanf(quot; %squot; ,&e.offspr);<br /> if(strlen(e.offspr)>1)<br /> goto a5;<br /> printf(quot; ENTER NO. OF OFFSPRING: quot; );<br /> scanf(quot; %dquot; ,&e.offno);<br /> printf(quot; FOOD SUPPLIED( IN KG): quot; );<br /> scanf(quot; %fquot; ,&e.food_s);<br /> printf(quot; FOOD CONSUMED( IN KG): quot; );<br /> scanf(quot; %fquot; ,&e.food_c);<br /> a2:<br /> printf(quot; ANIMAL DETAILS(IF ANY)(Don't leave space,use '_'): quot; );<br /> scanf(quot; %squot; ,e.anim_history);<br /> if(strlen(e.anim_history)>50)<br /> goto a2;<br /> fwrite(&e,lRecsize,1,fp);<br /> /*Flushes a stream On success returns 0 , On error returns EOF */<br /> fflush(stdin);<br /> }<br /> break;<br /> case '2':<br /> //Searching and displaying all the infor<br /> // mation by id<br /> textcolor(7);<br /> printf(quot; ENTER CELL ID: quot; );<br /> scanf(quot; %squot; ,cell_id);<br /> rewind(fp);<br /> while(fread(&e,lRecsize,1,fp)!=0)<br /> {<br /> if(strcmp(e.cellid,cell_id)==0)<br /> { iC=1;<br /> clrscr();<br /> //Display according to Main menu<br /> gotoxy(0,20);<br /> //ANIMAL<br /> if(iCh1==1){<br /> printf(quot; DETAILS OF THE ANIMAL:%squot; ,strupr(e.an_name));<br /> printf(quot; _____________________________________________________________________quot; );<br /> printf(quot; NAME : %s CELL ID : %s ZOO KEEPER NAME : %s SEX: %s AGE : %d OFFSPRING: %s OFFSPRING NO. : %d OFFSPRING RATIO : %f INBREED RATIO : %f FOOD SUPPLIED : %f FOOD CONSUMED : %f ANIMAL DETAILS: %squot; ,strupr(e.an_name),strupr(e.cellid),strupr(e.keeper_nm),strupr(e.an_sex),e.anim_age,strupr(e.offspr),e.offno,(e.offno/13.33*6.2),(e.offno*12.66/17.3574),e.food_s,e.food_c,strupr(e.anim_history));<br /> printf(quot; _____________________________________________________________________quot; );<br /> getch(); }<br /> //BIRD<br /> else if(iCh1==2){<br /> printf(quot; DETAILS OF BIRD:%squot; ,strupr(e.an_name));<br /> printf(quot; _____________________________________________________________________quot; );<br /> printf(quot; NAME : %s CELL ID : %s ZOO KEEPER NAME : %s AGE: %d SEX : %s OFFSPRING: %s OFFSPRING NO. : %d OFFSPRING RATIO : %f INBREED RATIO : %f FOOD SUPPLIED : %f FOOD CONSUMED : %f ANIMAL DETAILS: %squot; ,strupr(e.an_name),strupr(e.cellid),strupr(e.keeper_nm),e.anim_age,strupr(e.an_sex),strupr(e.offspr),e.offno,(e.offno/13.33*6.2),(e.offno*12.66/17.3574),e.food_s,e.food_c,strupr(e.anim_history));<br /> printf(quot; _____________________________________________________________________quot; );<br /> getch(); }<br /> }<br /> }<br /> if(iC==0)<br /> {<br /> printf(quot; RECORD DOESN'T EXISTS..quot; );<br /> getch();<br /> }iC=0;<br /> break;<br /> case '3':<br /> //Searching and modifying Records by id<br /> cAns='y';<br /> while(cAns=='y')<br /> {<br /> printf(quot; ENTER CELL ID: quot; );<br /> scanf(quot; %squot; ,cell_id);<br /> rewind(fp);<br /> while(fread(&e,lRecsize,1,fp)==1)<br /> {<br /> if(strcmp(e.cellid,cell_id)==0)<br /> {<br /> b:<br /> printf(quot; ENTER ANIMAL NAME: %s : quot; ,strupr(e.an_name));<br /> scanf(quot; %squot; ,e.an_name);<br /> if(strlen(e.an_name)>20||strlen(e.an_name)<3)<br /> goto b;<br /> b1:<br /> printf(quot; ENTER SEX : %s : quot; ,strupr(e.an_sex));<br /> scanf(quot; %squot; ,e.an_sex);<br /> if(strlen(e.an_sex)>1)<br /> goto b1;<br /> r:<br /> printf(quot; ENTER AGE: %d : quot; ,e.anim_age);<br /> scanf(quot; %dquot; ,&e.anim_age);<br /> if(e.anim_age<1||e.anim_age>100)<br /> goto r;<br /> ad:<br /> printf(quot; OFFSPRING : %s : quot; ,strupr(e.offspr));<br /> scanf(quot; %squot; ,e.offspr);<br /> if(strlen(e.offspr)<1)<br /> goto ad;<br /> printf(quot; ENTER NO. OF OFFSPRING: %d :quot; ,e.offno);<br /> scanf(quot; %dquot; ,&e.offno);<br /> printf(quot; ENTER FOOD SUPPLIED(IN KG): %f :quot; ,e.food_s);<br /> scanf(quot; %fquot; ,&e.food_s);<br /> printf(quot; FOOD CONSUMED( IN KG): quot; );<br /> scanf(quot; %fquot; ,&e.food_c);<br /> b5:<br /> printf(quot; ANIMAL DETAILS( IF ANY )(Dont leave space,use'_'instead)': %s : quot; ,e.anim_history);<br /> scanf(quot; %squot; ,e.anim_history);<br /> if(strlen(e.anim_history)>50)<br /> goto b5;<br /> fseek(fp,-lRecsize,SEEK_CUR); //Repositions the file pointer of a stream<br /> fwrite(&e,lRecsize,1,fp);<br /> printf(quot; RECORD MODIFIED quot; );<br /> break;<br /> }<br /> }<br /> printf(quot; DO U WANT TO MODIFY ANY RECORD[y/n]quot; );<br /> /*Flushes a stream On success returns 0 , On error returns EOF */<br /> fflush(stdin);<br /> cAns=getche();<br /> }<br /> break;<br /> case '4':<br /> //Searching and deleting records by id<br /> cAns='y';<br /> while(cAns=='y')<br /> {<br /> printf(quot; ENTER CELL ID TO DELETE RECORD : quot; );<br /> scanf(quot; %squot; ,cell_id);<br /> ft=fopen(quot; temp.datquot; ,quot; wbquot; );<br /> rewind(fp); //Repositions file pointer to stream's beginning<br /> while(fread(&e,lRecsize,1,fp)!=0)<br /> {<br /> if(strcmp(e.cellid,cell_id)!=0) {<br /> fwrite(&e,lRecsize,1,ft);<br /> }<br /> else {<br /> iF1=1;<br /> printf(quot; RECORD DELETED SUCCESSFULLYquot; );<br /> }<br /> }<br /> if(iF1!=1){iF1=0;<br /> printf(quot; NO SUCH RECORD FOUNDquot; );}<br /> fclose(fp);<br /> fclose(ft);<br /> remove(quot; zm.datquot; );<br /> rename(quot; temp.datquot; ,quot; zm.datquot; );<br /> fp=fopen(quot; zm.datquot; ,quot; rb+quot; );<br /> printf(quot; DO U WANT TO DELETE ANOTHER RECORD[y/n]quot; );<br /> fflush(stdin);<br /> cAns=getche();<br /> }<br /> break;<br /> case '5':<br /> fclose(fp);<br /> goto e;<br /> }<br /> }<br /> }<br /> }<br />