[ Home  |  FAQ-Related Q&As  |  General Q&As  |  Answered Questions ]


    Search the Q&A Archives


CAN YOU GIVE A SAMPLE PROGRAM ON HOW TO MAKE A PROGRAM IN...

<< Back to general questions

Question by MONA
Submitted on 3/10/2004
Related FAQ: N/A
Rating: Rate this question: Vote
CAN YOU GIVE A SAMPLE PROGRAM ON HOW TO MAKE A PROGRAM IN TURBO C USING MIND STAMP ROBOT



Answer by monmon
Submitted on 10/9/2005
Rating: Not yet rated Rate this answer: Vote
cabang

 

Answer by Arone
Submitted on 9/25/2006
Rating: Not yet rated Rate this answer: Vote
yes! because i need one a program of turbo

 

Answer by paul
Submitted on 2/6/2007
Rating: Not yet rated Rate this answer: Vote
#include<stdio.h>
#include<conio.h>
#include<string.h>



int count=0;
struct address_book
{
char name[30];
long bday;
int age;
int number;
char street[20];
char brgy[20];
char city[20];
int zip;
}list[9];

main()
{
int x;
clrscr();
for(x=0; x<9; x++)
{
clrscr();
printf("\n Entry no. %d",x+1);
printf("\n Name : ");
scanf("%s",&list[x].name);
printf(" Birthday : ");
scanf("%li",&list[x].bday);
printf(" Age : ");
scanf("%d",&list[x].age);
printf("\n ADDRESS: Number : ");
scanf("%i",&list[x].number);
printf("\n Street : ");
scanf("%s",&list[x].street);
printf(" Brgy. : ");
scanf("%s",&list[x].brgy);
printf(" City : ");
scanf("%s",&list[x].city);
printf(" Zip : ");
scanf("%i",&list[x].zip);
printf("\n\n Contents for entry %d complete!",x+1);
printf("\n Press any key to proceed to the next entry...");
getch();

}
show();
}
show()
{
int x, y, row, col;
clrscr();
row=1;
for(x=0; x<3; x++)
{
col=1;
for(y=0; y<3; y++)
{
gotoxy(col,row);
printf(" ENTRY %d",count+1);
gotoxy(col,row+1);
printf(" Name : %s",list[count].name);
gotoxy(col,row+2);
printf(" Birthday: %li",list[count].bday);
gotoxy(col,row+3);
printf(" Age : %d",list[count].age);
gotoxy(col,row+4);
printf(" ADDRESS: No.: %d",list[count].number);
gotoxy(col,row+5);
printf(" Street : %s",list[count].street);
gotoxy(col,row+6);
printf(" Brgy : %s",list[count].brgy);
gotoxy(col,row+7);
printf(" City : %s",list[count].city);
gotoxy(col,row+8);
printf(" Zip : %d",list[count].zip);
col=col+26;
count=count++;
}
row=row+8;
}
getch();
main2();
}
main2()
{
char choice;
clrscr();
printf("\n What do you want to do\?\n");
printf("\n [1] Search");
printf("\n [2] Exit");
printf("\n > ");
choice=getch();
switch(choice)
{
case '1':
search();

case '2':
exit();

default:
main2();
}
}
search()
{
int x;
char search[30], search_name[9];
char search_street[9], search_brgy[9];
char search_city[9];
clrscr();
printf("\n SEARCH ENTRY \n");
printf("\n Enter entry keyword: ");
scanf("%s",&search);
printf("\n\n searching database...");
for(x=0; x<10; x++)
{
if(!strcmp(search,list[x].name))
{
search_name[x]=1;
}
if(!strcmp(search,list[x].street))
{
search_street[x]=1;
}
if(!strcmp(search,list[x].brgy))
{
search_brgy[x]=1;
}
if(!strcmp(search,list[x].city))
{
search_city[x]=1;
}
}
clrscr();
printf("\n RESULTS BELOW:");

for(x=0; x<9;x++)
{
if(search_name[x]==1)
{
printf("\n Result found on entry %d on the 'Name' field.",x+1);
}
if(search_street[x]==1)
{
printf("\n Result found on entry %d on the 'Street' field.",x+1);
}
if(search_brgy[x]==1)
{
printf("\n Result found on entry %d on the 'Brgy' field.",x+1);
}
if(search_city[x]==1)
{
printf("\n Result found on entry %d on the 'City' field.",x+1);
}
}

printf("\n\n\n Press any key to go back to Menu...");
getch();
main2();

}

 

Answer by liza
Submitted on 2/21/2007
Rating: Not yet rated Rate this answer: Vote
for example how to convert the ordinary number to roman numeral?

 

Answer by rashel
Submitted on 3/6/2007
Rating: Not yet rated Rate this answer: Vote













































 

Your answer will be published for anyone to see and rate.  Your answer will not be displayed immediately.  If you'd like to get expert points and benefit from positive ratings, please create a new account or login into an existing account below.


Your name or nickname:
If you'd like to create a new account or access your existing account, put in your password here:
Your answer:

FAQS.ORG reserves the right to edit your answer as to improve its clarity.  By submitting your answer you authorize FAQS.ORG to publish your answer on the WWW without any restrictions. You agree to hold harmless and indemnify FAQS.ORG against any claims, costs, or damages resulting from publishing your answer.

 

FAQS.ORG makes no guarantees as to the accuracy of the posts. Each post is the personal opinion of the poster. These posts are not intended to substitute for medical, tax, legal, investment, accounting, or other professional advice. FAQS.ORG does not endorse any opinion or any product or service mentioned mentioned in these posts.

 

<< Back to general questions


[ Home  |  FAQ-Related Q&As  |  General Q&As  |  Answered Questions ]

© 2008 FAQS.ORG. All rights reserved.