English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

Programming & Design - November 2006

[Selected]: All categories Computers & Internet Programming & Design

I'm a total blank. How do you create a link to a website directly into your answer (ex. http://www.espn.com)?

2006-11-20 00:03:10 · 3 answers · asked by DJ 5

this is in adobe photoshop cs. I want to get some part from a picture, like a face, and put it in a different picture. How do I do it?

2006-11-19 22:59:04 · 5 answers · asked by Anonymous

# include
# include
# include
# include
# include
# include
# include
# include
# include
# include
# define p 240

char strin[20];
//following functions are used by the programmer to
//edit,append,delete data using progmammer function
//which can be accessed by pass function.
void pass(void);
void edit(void);
void append(void);
void recshow(void);
void dodelete(void);
void programmer(void);

//structure declaration to store names of
//trains and attractions.
struct arr{ char name[5][20]; };
struct tr { char names[2][20]; };
//declaration of class TOUR
class TOUR{
private:
char destination[20];
char state[20];
char season[20];
char cost[20];
tr trains;
tr timings;
arr attractions;
tr hotels;
char type[20];
char sp[160];
public:
void read_data(void);
void show_data(void);
int compare(char string[20])
{
if (strcmp(destination,string)==0)
return 1;
else
return 0;
}
void give_destination()
{
strcpy(strin,destination);}
}
//globally defined objects for class TOUR.
twork,worker;
//function used in the program to hold the screen
void wait(void)
{
cout<<"\nPRESS ANY KEY TO CONINUE \n";
getch();
}
//public function of class TOUR which reads data input by the programmer
void TOUR::read_data()
{
clrscr();
int blank,x,i,j,l;
cout<<"\n-----------------------------------ENTER DATA------------";
cout<<"---------------------- \n";
cout<<"DESTINATION "; gets(destination);
l=strlen(destination);
for (j=0;j<=l;j++)
destination[j]=toupper(destination[j]);
blank=20-strlen(destination);
for(x=1;x<=blank;x++)
strcat(destination," ");
destination[19]='\0';

cout<<"STATE "; gets(state);
l=strlen(state);
for(j=0;j<=l;j++)
state[j]=toupper(state[j]);
blank=20-strlen(state);
for (x=1;x<=blank;x++)
strcat(state," ");
state[19]='\0';

cout<<"SEASON "; gets(season);
l=strlen(season);
for(j=0;j<=l;j++)
season[j]=toupper(season[j]);
blank=20-strlen(season);
for(x=1;x<=blank;x++)
strcat(season," ");
season[19]='\0';

cout<<"COST "; gets(cost);
l=strlen(cost);
for(j=0;j<=l;j++)
cost[j]=toupper(cost[j]);
blank=20-strlen(cost);
for(x=1;x<=blank;x++)
strcat(cost," ");
cost[19]='\0';

cout<<"TRAINS ";
for (j=0;j<2;j++)
{
gets(trains.names[j]);
l=strlen(trains.names[j]);
for(i=0;i<=l;i++)
trains.names[j][i]=toupper(trains.names[j][i]);
blank=20-strlen(trains.names[j]);
for(x=1;x<=blank;x++)
strcat(trains.names[j]," ");
trains.names[j][19]='\0';
}

cout<<"TIMINGS ";
for (j=0;j<2;j++)
{
gets(timings.names[j]);
l=strlen(timings.names[j]);
for(i=0;i<=l;i++)
timings.names[j][i]=toupper(timings.names[j][i]);
blank=20-strlen(timings.names[j]);
for(x=1;x<=blank;x++)
strcat(timings.names[j]," ");
timings.names[j][19]='\0';
}

cout<<"ATRRACTIONS ";
for(i=0;i<5;i++)
{
gets(attractions.name[i]);
l=strlen(attractions.name[i]);
for(j=0;j<=l;j++)
attractions.name[i][j]=toupper(attractions.name[i][j]);
blank=20-strlen(attractions.name[i]);
for(x=1;x<=blank;x++)
strcat(attractions.name[i]," ");
attractions.name[i][19]='\0';
}

cout<<"HOTELS ";
for (j=0;j<2;j++)
{
gets(hotels.names[j]);
l=strlen(hotels.names[j]);
for(i=0;i<=l;i++)
hotels.names[j][i]=toupper(hotels.names[j][i]);
blank=20-strlen(hotels.names[j]);
for(x=1;x<=blank;x++)
strcat(hotels.names[j]," ");
hotels.names[j][19]='\0';
}

cout<<"TYPE "; gets(type);
l=strlen(type);
for(j=0;j<=l;j++)
type[j]=toupper(type[j]);
blank=20-strlen(type);
for(x=1;x<=blank;x++)
strcat(type," ");
type[19]='\0';

cout<<"SPECIALITY "; gets(sp);
l=strlen(sp);
for(j=0;j<=l;j++)
sp[j]=toupper(sp[j]);
blank=20-strlen(sp);
for(x=1;x<=blank;x++)
strcat(sp," ");
sp[159]='\0';
}
//public function of class TOUR which displays data on the screen
void TOUR::show_data()
{
clrscr();
cout<<"\n*************************VARIOUS TOURIST PLACES ARE AS***";
cout<<"************************\n";
cout< cout< "< "< cout< "< "< cout< "< "
< cout< < cout< "< "
< cout< < cout< "
< cout< cout< cout< cout< cout<<"\n********************************************************";
cout<<"***********************\n";
wait();
}

void recshow()
{
clrscr();
fstream tfile("tourism.dat",ios::binary|ios::out|ios::in);
cout<<"CONTENTS OF FILE ARE AS\n";
tfile.seekg(0,ios::beg);
tfile.read((char*)&worker,sizeof(TOUR));
while (!tfile.eof())
{
worker.show_data();
tfile.read((char*)&worker,sizeof(TOUR));
}
tfile.close();
cout<<" DESIRED RECORD(S) ARE DISLPLAYED \n";
}

void append()
{
clrscr();
char ch;
int recno;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::end);
recno=tfile.tellg()/sizeof(TOUR);
cout<<"\n NO OF RECORDS IN FILE ARE AS "< do
{ cout<<"\n WANT TO ENTER MORE DATA Y/N \n";
ch=toupper(getche());
if (ch=='Y')
{
cout<<"\n RECORD NUMBER "< twork.read_data();
twork.give_destination();
cout<<"\n YOUR DESTINATION WAS "< tfile.seekg(0,ios::beg);
int found=0;
while (!tfile.eof()&&!found)
{
tfile.read((char*)&worker,sizeof(TOUR));
if (worker.compare(strin))
found=1;
}
if (!found)
{
tfile.clear();
recno++;
tfile.seekp(0,ios::end);
tfile.write((char*)&twork,sizeof (TOUR));
cout<<" \nNEW RECORD IS ENTERED SUCCESFULLY\n";
}
else
{
cout<<" !!! THIS DESTINATION ALREADY EXISTS !!!\n";
wait();
recshow();
}
}
}
while(ch=='Y');
tfile.close();
}

void edit()
{
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
cout<<"ENTER DESTINATION FOR WHICH YOU WANT TO EDIT RECORD \n";
gets(strin);
int l=strlen(strin);
for (int j=0;j<=l;j++)
strin[j]=toupper(strin[j]);
int blank=20-strlen(strin);
for(int x=1;x strcat(strin," ");
strin[19]='\0';
int found=0;
while (!tfile.eof() && !found)
{
tfile.read((char*)&worker,sizeof(TOUR));
if (worker.compare(strin))
found=1;
}
if(!found)
cout<<"\n NO RECORD FOUND FOUND IN THIS DESTINATION\n";
else
{
worker.show_data();
worker.read_data();
tfile.seekp(tfile.tellp()-sizeof(worker));
tfile.write((char*)&worker,sizeof(TOUR));
cout<<" EDITED RECORD IS SAVED SUCCESSFULLY \n";
}
wait();
tfile.close();
}

void dodelete()
{
fstream tfile ("tourism.dat",ios::binary|ios::out|ios::in);
int found=0;
char ok;
cout<<"\n ENTER DESTINATION TO DELETE THE RECORD\n";
gets(strin);
int l=strlen(strin);
for (int j=0;j<=l;j++)
strin[j]=toupper(strin[j]);
int blank=20-strlen(strin);
for(int x=1;x strcat(strin," ");
strin[19]='\0';
while (!tfile.eof()&&!found)
{
tfile.read((char*)&worker,sizeof(worker));
if(worker.compare(strin))
found=1;
}
if(!found)
{
cout<<"\n NO SUCH RECORD FOUND\n";
wait();
}
else
{
recshow();
cout<<"\nWANT TO DELETE THIS RECORD Y/N \n";
ok=toupper(getche());
if(ok=='Y')
{
fstream mtemp("temp.dat",ios::binary|ios::in|ios::out);
tfile.seekg(ios::beg);
tfile.read((char*)&worker,sizeof(worker));
tfile.clear();
while(!tfile.eof())
{
if(!worker.compare(strin))
mtemp.write((char*)&worker,sizeof(worker));
tfile.read((char*)&worker,sizeof(worker));
}
tfile.close();
mtemp.close();
remove("tourism.dat");
if (rename("temp.dat","tourism.dat")==0)
cout<<"\nêêê RECORD IS DELETED SUCCESSFULLY êêê\n";
else
cout<<"\n!!!OPERATION IS UNSUCCESSFUL!!!\n";
wait();
}
}
}

void pass()
{
clrscr();
clearviewport();
int c=0,y=0;
char pass_word[20];
const char password[]={"210785"};
while(c<2)
{
c++;
setbkcolor(BLUE);
for (y=1;y<14;y++)
cout << endl;
cout << "\t\têêê ENTER YOUR PASSWORD êêê\n";
gotoxy(50,14);
gets(pass_word);
if(strcmp(password,pass_word)==0)
{
programmer();
break;
}
else
cout<<"ëëë BAD LUCK PASSWORD IS WRONG ëëë";
if (c<2)
//textattr(RED+BLINK);
//cprintf("\n²²² TRY ONCE MORE ²²²\r\n");
cprintf("\n²²² TRY ONCE MORE ²²²\r\n");
}
wait();
}

void programmer(void)
{
//setbkcolor(BLUE);
// textbackground(BLUE);
int ok,y;
do {
clrscr();
clearviewport();
setbkcolor(BLUE);

for(y=1;y<=3;y++)
cout<<"\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\t ";
cout<<"ENTER CHOICE & PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\t\tAPPEND RECORD ---> 1 \t\t\t\t";
cout<<"\t\t\t\tEDIT RECORD ---> 2 \t\t\t\t";
cout<<"\t\t\t\tDELETE RECORD ---> 3 \t\t\t\t";
cout<<"\t\t\t\tSHOW RECORD ---> 4 \t\t\t\t";
cout<<"\t\t\t\tEXIT ---> 5 \t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=0;y<20;y++)
cout<<"\t\t\t\t\t ";
cout << "\t\t\t\t Enter choice : ";
cin>>ok;

switch(ok)
{
case 1:append();
break;
case 2: edit();
break;
case 3: dodelete();
break;
case 4: recshow();
break;
case 5:break;
default:cout<<" INVALID CHOICE \n";delay(1500);break;
}
} while(ok!=5);
}
//class which acssess the data
class TRAVEL { private:
char dest[20];
char st[20];
char seas[20];
char ct[20];
tr tra;
tr timing;
arr attract;
tr hotel;
char ty[20];
char special[160];
public:
void get_state(char tt[20]);
void get_attract(char tt[20]);
void get_read();
void get_alpha(char tt[20]);
void get_all(char tt[20]);
void get_dest(char tt[20]);
void get_season(char tt[20]);
void get_cost(char tt[20]);
void dest_seas();
void seas_state();
void state_cost();
void all();
} abc,pqr;
//member function of class TRAVEL which acssess the data.
void TRAVEL::get_read()
{
clrscr();
cout<<"\n*************************VARIOU TOURIST PLACES ARE AS***";
cout<<"************************\n";
cout< cout< "< "< cout< "< "< cout< "< "
<
cout< < cout< "< "
< cout< < cout< cout< cout< cout< cout< cout<<"\n********************************************************";
cout<<"************************\n";
wait();
}
//member function of class TRAVEL which compares destination and season
//input by the user and displays data corresponding to the same.
void TRAVEL::dest_seas()
{
char ch,destination[20],season[20];
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER DESTINATION & SEASON FOR WHICH INFORMATION IS TO BE";
cout<<" DISPLAYED\n";
cout<<"DESTINATION "; gets(destination);
cout<<"SEASON ";gets(season);
int l=strlen(destination);
for (int j=0;j<=l;j++)
destination[j]=toupper(destination[j]);
int blank=20-strlen(destination);
for(int x=1;x strcat(destination," ");
destination[19]='\0';
l=strlen(season);
for (j=0;j<=l;j++)
season[j]=toupper(season[j]);
blank=20-strlen(season);
for(x=1;x strcat(season," ");
season[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if ((strcmp(dest,destination)==0)&&(strcmp(seas,season)==0))
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if ((i==0)&&(ch=='Y'))
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares the state and cost
//input by the user and displays the data corresonding to the same.
void TRAVEL::state_cost()
{
char ch,state[20],cost[20];
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER STATE & COST RANGE FOR WHICH ";
cout<<"INFORMATION IS TO BE DISPLAYED\n";
cout<<"STATE "; gets(state);
cout<<"COST RANGE ";gets(cost);
int l=strlen(state);
for (int j=0;j<=l;j++)
state[j]=toupper(state[j]);
int blank=20-strlen(state);
for(int x=1;x strcat(state," ");
state[19]='\0';
blank=20-strlen(cost);
for(x=1;x strcat(cost," ");
cost[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if ((strcmp(st,state)==0)&&(strcmp(ct,cost)==0))
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if ((i==0)&&(ch=='Y'))
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\nHAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares the season and state
//input by the user and displays data corresponding to the same.
void TRAVEL::seas_state()
{
char ch,state[20],season[20];
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER STATE & SEASON FOR WHICH INFORMATION IS TO BE DISPLAYED\n";
cout<<"STATE "; gets(state);
cout<<"SEASON ";gets(season);
int l=strlen(state);
for (int j=0;j<=l;j++)
state[j]=toupper(state[j]);
int blank=20-strlen(state);
for(int x=1;x strcat(state," ");
state[19]='\0';
l=strlen(season);
for (j=0;j<=l;j++)
season[j]=toupper(season[j]);
blank=20-strlen(season);
for(x=1;x strcat(season," ");
season[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if ((strcmp(st,state)==0)&&(strcmp(seas,season)==0))
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if ((i==0)&&(ch=='Y'))
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\nHAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which displays the entire data of the file.
void TRAVEL::all()
{
char ch;
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"WANT TO SEE ALL RECORD Y/N"< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while(!(tfile.eof())&&(ch=='Y'))
{
i++;
abc.get_read();
cout<<"WANT TO SEE MORE RECORDS Y/N \n";
ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if ((i==0)&&(ch=='Y'))
cout<<"\n NO RECORD FOUND";
else
cout<<"\nHAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares state input by the user and
//displays data corresponding to same.
void TRAVEL::get_state(char tt[20])
{
char ch,state[20];
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER STATE FOR WHICH INFORMATION IS TO BE DISPLAYED\n";
gets(state);
int l= strlen(state);
for (int j=0;j<=l;j++)
state[j]=toupper(state[j]);
int blank=20-strlen(state);
for(int x=1;x strcat(state," ");
state[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if ((strcmp(st,state)==0)&&(strcmp(ty,tt)==0))
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if ((i==0)&&(ch=='Y'))
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares attractions
//input by the user and displays data corresponding to same.
void TRAVEL::get_attract(char tt[20])
{
char ch,attraction[20],att[20];
int i=0,j=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER ATTRACTION/NAME OF TEMPLE OR MOSQUE/NAME OF GOD/FESTIVALS";
cout<<"/FORTS AND PALACES FOR WHICH INFORMATION IS TO BE DISPLAYED\n";
gets(attraction);
int l=strlen(attraction);
for (j=0;j<=l;j++)
attraction[j]=toupper(attraction[j]);
int blank=20-strlen(attraction);
for(int x=1;x<=blank;x++)
strcat(attraction," ");
attraction[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
for (j=0;j<5;j++)
{
strcpy(att,attract.name[j]);
if ((strcmp(att,attraction)==0)&&(strcmp(ty,tt)==0))
{
abc.get_read();
i++;
}
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if (i==0)
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares type
//chosen by the user and displays all data for the same.
void TRAVEL::get_all(char tt[20])
{
char ch;
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"WANT ALL DESTINATIONS TO BE DISPLAYED Y/N \n"< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if (strcmp(ty,tt)==0)
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if (i==0)
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares cost range input by the
//user and displays data corresponding to the same.
void TRAVEL::get_cost(char tt[20])
{
char ch,cost[20];
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER COST RANGE FOR WHICH INFORMATION IS TO BE DISPLAYED\n";
gets(cost);
int l=strlen(cost);
for (i=0;i<=l;i++)
strcat(cost," ");
cost[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if ((strcmp(ct,cost)==0)&&(strcmp(ty,tt)==0))
{
abc.get_read();
i++;
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if ((i==0)&&(ch=='Y'))
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares season input by the user
//and displays data corresponding to the same.
void TRAVEL::get_season(char tt[20])
{
char ch,season[20];
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER SEASON SUCH AS OCTOBER TO NOVEMBER FOR WHICH INFORMATION";
cout<<"IS TO BE DISPLAYED \n";
gets(season);
int l=strlen(season);
for(int j=0;j<=l;j++)
season[j]=toupper(season[j]);
int blank=20-strlen(season);
for(int x=1;x strcat(season," ");
season[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if ((strcmp(seas,season)==0)&&(strcmp(ty,tt)==0))
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if (i==0)
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares destination input by the
//user and displays data corresponding to that.
void TRAVEL::get_dest(char tt[20])
{
char ch,destination[20];
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER DESTINATION FOR WHICH INFORMATION IS TO BE DISPLAYED \n";
gets(destination);
int l=strlen(destination);
for(int j=0;j<=l;j++)
destination[j]=toupper(destination[j]);
int blank=20-strlen(destination);
for (int x=1;x strcat(destination," ");
destination[19]='\0';
cout<<"WANT TO FIND RECORD FOR "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if ((strcmp(dest,destination)==0)&&(strcmp(ty,tt)==0))
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if (i==0)
cout<<"\n !!!NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//member function of class TRAVEL which compares alphabet input by the user
//and displays data starting from same.
void TRAVEL::get_alpha(char tt[20])
{
char ch,alpha;
int i=0;
fstream tfile("tourism.dat",ios::binary|ios::in|ios::out);
tfile.seekg(0,ios::beg);
cout<<"ENTER ALPHABET FOR WHICH INFORMATION IS TO BE DISPLAYED \n";
alpha=toupper(getche());
cout<<"\n WANT TO FIND RECORD STARTING FROM "< ch=toupper(getch());
tfile.read((char*)&abc,sizeof(TRAVEL));
while (!(tfile.eof())&&(ch=='Y'))
{
if((alpha==dest[0])&&(strcmp(ty,tt)==0))
{
i++;
abc.get_read();
}
tfile.read((char*)&abc,sizeof(TRAVEL));
}
tfile.close();
if (i==0)
cout<<"\n NO RECORD FOUND FOR "< else
cout<<"\n HAVE A GOOD DAY \n";
wait();
}
//FUNCTION TO BE CALLED WHEN USER WANTS TO SEE HILL STATIONS.
void hill()
{
int ok,blank,y;
char type[20]={"HILL STATION" };
blank=20-strlen(type);
for(int i=1;i<=blank;i++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for (y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;
cout<<"\t\t\tENTER CHOICE & PRESS ENTER \t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tNAME OF DESTINATION----> 1 \t\t\t\t";
cout<<"\t\t\tSTATE WISE DISPLAY-----> 2 \t\t\t\t";
cout<<"\t\t\tA PARTICULAR ALPHABET--> 3 \t\t\t\t";
cout<<"\t\t\tCOST RANGE-------------> 4 \t\t\t\t";
cout<<"\t\t\tSEASON-----------------> 5 \t\t\t\t";
cout<<"\t\t\tALL HILL STATIONS------> 6 \t\t\t\t";
cout<<"\t\t\tPARTICULAR ATTRACTION--> 7 \t\t\t\t";
cout<<"\t\t\tEXIT-------------------> 8 \t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for (y=1;y<12;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;
cout << "\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1: abc.get_dest(type);
break;
case 2: abc.get_state(type);
break;
case 3: abc.get_alpha(type);
break;
case 4: abc.get_cost(type);
break;
case 5: abc.get_season(type);
break;
case 6: abc.get_all(type);
break;
case 7: abc.get_attract(type);
break;
case 8: break;
default:cout<<"invalid choice \n";delay(1500);break;
}
}
while(ok!=8);
}
// FUNCTION TO BE CALLED WHEN USER CHOOSES TO SEE SOUTHERN DESTINATIONS.
void south()
{
int ok,y;
char type[20]={"SOUTH"};
int blank=20-strlen(type);
for (int l=1;l<=blank;l++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;
cout<<"\t ENTER CHOICE & PRESS ENTER\t\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t NAME OF DESTINATION-----------> 1\t\t\t\t";
cout<<"\t STATE WISE DISPLAY------------> 2\t\t\t\t";
cout<<"\t A PARTICULAR ALPHABET---------> 3\t\t\t\t";
cout<<"\t COST RANGE--------------------> 4\t\t\t\t";
cout<<"\t SEASON------------------------> 5\t\t\t\t";
cout<<"\t ALL SOUTHERN DESTINATIONS-----> 6\t\t\t\t";
cout<<"\t FESTIVALS OF SOUTH------------> 7\t\t\t\t";
cout<<"\t EXIT--------------------------> 8\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<12;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t Enter choice : ";
cin>>ok;
switch(ok)
{
case 1: abc.get_dest(type);
break;
case 2:abc.get_state(type);
break;
case 3:abc.get_alpha(type);
break;
case 4:abc.get_cost(type);
break;
case 5:abc.get_season(type);
break;
case 6:abc.get_all(type);
break;
case 7:abc.get_attract(type);
break;
case 8: break;
default:cout<<" INVALID CHOICE \n";delay(1500);break;
}
}
while(ok!=8);
}
//FUNCTION TO BE CALLED WHEN USER CHOOSES TO SEE RELIGIOUS PLACES.
void religion()
{
int ok,y;
char type[20]={"RELIGIOUS"};
int blank=20-strlen(type);
for (int l=1;l<=blank;l++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;
cout<<"\t\t\tENTER CHOICE AND PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tNAME OF DESTINATION----> 1\t\t\t\t";
cout<<"\t\t\tSTATE WISE DISPLAY-----> 2\t\t\t\t";
cout<<"\t\t\tA PARTICULAR ALPHABET--> 3\t\t\t\t";
cout<<"\t\t\tCOST RANGE-------------> 4\t\t\t\t";
cout<<"\t\t\tSEASON-----------------> 5\t\t\t\t";
cout<<"\t\t\tALL RELIGIOUS PLACES---> 6\t\t\t\t";
cout<<"\t\t\tNAME OF GOD------------> 7\t\t\t\t";
cout<<"\t\t\tNAME OF TEMPLE/MOSQUE--> 8\t\t\t\t";
cout<<"\t\t\tEXIT-------------------> 9\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<12;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1:abc.get_dest(type);
break;
case 2:abc.get_state(type);
break;
case 3:abc.get_alpha(type);
break;
case 4:abc.get_cost(type);
break;
case 5:abc.get_season(type);
break;
case 6:abc.get_all(type);
break;
case 7:abc.get_attract(type);
break;
case 8:abc.get_attract(type);
break;
case 9: break;
default:cout<<"invalid choice \n";delay(1500);break;
}
}
while(ok!=9);
}
//FUNCTION TO BE CALLED WHEN USER WANTS TO SEE SEA BEACHES.
void seas()
{
int ok,y;
char type[20]={"BEACH"};
int blank=20-strlen(type);
for (int l=1;l<=blank;l++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;
cout<<"\t\t\tENTER CHOICE & PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tNAME OF DESTINATION----> 1\t\t\t\t";
cout<<"\t\t\tSTATE WISE DISPLAY-----> 2\t\t\t\t";
cout<<"\t\t\tA PARTICULAR ALPHABET--> 3\t\t\t\t";
cout<<"\t\t\tCOST RANGE-------------> 4\t\t\t\t";
cout<<"\t\t\tSEASON-----------------> 5\t\t\t\t";
cout<<"\t\t\tALL BEACHES------------> 6\t\t\t\t";
cout<<"\t\t\tPARTICULAR ATTRACTION--> 7\t\t\t\t";
cout<<"\t\t\tEXIT-------------------> 8\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<11;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout <<"\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1:abc.get_dest(type);
break;
case 2:abc.get_state(type);
break;
case 3:abc.get_alpha(type);
break;
case 4:abc.get_cost(type);
break;
case 5:abc.get_season(type);
break;
case 6:abc.get_all(type);
break;
case 7:abc.get_attract(type);
break;
case 8: break;
default:cout<<"invalid choice \n"; delay(1500); break;
}
}
while(ok!=8);
}
//FUNCTION TO BE CALLED WHEN USER WANTS TO SEE WILD LIFE SANCTURIES.
void sancturies()
{
int ok,y;
char type[20]={"SANCTURIES"};
int blank=20-strlen(type);
for (int l=1;l<=blank;l++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;
cout<<"\t\t\tENTER CHOICE & PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tNAME OF DESTINATION---------> 1\t\t\t\t";
cout<<"\t\t\tSTATE WISE DISPLAY----------> 2\t\t\t\t";
cout<<"\t\t\tA PARTICULAR ALPHABET-------> 3\t\t\t\t";
cout<<"\t\t\tCOST RANGE------------------> 4\t\t\t\t";
cout<<"\t\t\tSEASON----------------------> 5\t\t\t\t";
cout<<"\t\t\tALL WILD LIFE SANCTURIES----> 6\t\t\t\t";
cout<<"\t\t\tPARTICULAR ATTRACTION-------> 7\t\t\t\t";
cout<<"\t\t\tEXIT------------------------> 8\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<11;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1:abc.get_dest(type);
break;
case 2:abc.get_state(type);
break;
case 3:abc.get_alpha(type);
break;
case 4:abc.get_cost(type);
break;
case 5:abc.get_season(type);
break;
case 6:abc.get_all(type);
break;
case 7:abc.get_attract(type);
break;
case 8: break;
default:cout<<"invalid choice \n";delay(1500);break;
}
}
while(ok!=8);
}
//FUNCTION TO BE CALLED WHEN USER WANTS TO SEE LIST OF SHOPPING CENTRES.
void shopping()
{
int ok,y;
char type[20]={"SHOPPING"};
int blank=20-strlen(type);
for (int l=1;l<=blank;l++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<8;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tENTER CHOICE & PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tNAME OF DESTINATION---------> 1\t\t\t\t";
cout<<"\t\t\tALL SHOPPING CENTRES--------> 2\t\t\t\t";
cout<<"\t\t\tPARTICULAR ATTRACTION-------> 3\t\t\t\t";
cout<<"\t\t\tEXIT------------------------> 4\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------\n";
for(y=1;y<11;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1:abc.get_dest(type);
break;
case 2:abc.get_all(type);
break;
case 3:abc.get_attract(type);
break;
case 4:
break;
default:cout<<"invalid choice \n";delay(1500);break;
}
}
while(ok!=4);
}
//FUNCTION TO BE CALLED WHEN USER WANTS TO SEE HISTORICAL PLACES.
void historical()
{
int ok,y;
char type[20]={"HISTORICAL"};
int blank=20-strlen(type);
for (int l=1;l<=blank;l++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tENTER CHOICE & PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tNAME OF DESTINATION---------> 1\t\t\t\t";
cout<<"\t\t\tSTATE WISE DISPLAY----------> 2\t\t\t\t";
cout<<"\t\t\tA PARTICULAR ALPHABET-------> 3\t\t\t\t";
cout<<"\t\t\tCOST RANGE------------------> 4\t\t\t\t";
cout<<"\t\t\tALL HISTORICAL PLACES-------> 5\t\t\t\t";
cout<<"\t\t\tFORTS AND PALACES-----------> 6\t\t\t\t";
cout<<"\t\t\tEXIT------------------------> 7\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<12;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1:abc.get_dest(type);
break;
case 2:abc.get_state(type);
break;
case 3:abc.get_alpha(type);
break;
case 4:abc.get_cost(type);
break;
case 5:abc.get_all(type);
break;
case 6:abc.get_attract(type);
break;
case 7:
break;
default:cout<<"invalid choice \n";delay(1500);break;
}
}
while(ok!=7);
}
//FUNCTION TO BE CALLED WHEN USER WANTS TO SEE EASTERN PLACES.
void east()
{
int ok,y;
char type[20]={"EAST"};
int blank=20-strlen(type);
for (int l=1;l<=blank;l++)
strcat(type," ");
type[19]='\0';
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tENTER CHOICE & PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tNAME OF DESTINATION---------> 1\t\t\t\t";
cout<<"\t\t\tSTATE WISE DISPLAY----------> 2\t\t\t\t";
cout<<"\t\t\tA PARTICULAR ALPHABET-------> 3\t\t\t\t";
cout<<"\t\t\tCOST RANGE------------------> 4\t\t\t\t";
cout<<"\t\t\tSEASON----------------------> 5\t\t\t\t";
cout<<"\t\t\tALL EASTERN DESTINATIONS----> 6\t\t\t\t";
cout<<"\t\t\tPARTICULAR ATTRACTION-------> 7\t\t\t\t";
cout<<"\t\t\tEXIT------------------------> 8\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<12;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1:abc.get_dest(type);
break;
case 2:abc.get_state(type);
break;
case 3:abc.get_alpha(type);
break;
case 4:abc.get_cost(type);
break;
case 5:abc.get_season(type);
break;
case 6:abc.get_all(type);
break;
case 7:abc.get_attract(type);
break;
case 8: break;
default:cout<<"invalid choice \n";delay(1500);break;
}
}
while(ok!=8);
}
//FUNCTION TO BE CALLED WHEN USER WANTS EXTRA INFORMATION FOR ALL TYPE OF
//PLACES .
void extra(void)
{
int ok,y;
do
{
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tENTER CHOICE & PRESS ENTER\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\tDESTINATION & SEASON------> 1\t\t\t\t";
cout<<"\t\t\tSTATE & SEASON ------> 2\t\t\t\t";
cout<<"\t\t\tSTATE & COST ------> 3\t\t\t\t";
cout<<"\t\t\tALL ------> 4\t\t\t\t";
cout<<"\t\t\tEXIT ------> 5\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<14;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\tEnter choice : ";
cin>>ok;
switch(ok)
{
case 1:abc.dest_seas();
break;
case 2:abc.seas_state();
break;
case 3:abc.state_cost();
break;
case 4:abc.all();
break;
case 5: break;
default:cout<<"Invalid Choice \n";delay(1500);break;
}
}
while(ok!=5);
}

// FUNCTION FOR THE FIRST SCREEN.
void starter()
{
clearviewport();
char s;

while(!kbhit())
{

for(int i=0;i<3;i++)
{
circle(20,20,40+5*i);
circle(618,20,40+5*i);
circle(20,458,40+5*i);
circle(618,458,40+5*i);
circle(320,20,40+5*i);
circle(320,458,40+5*i);
circle(20,240,40+5*i);
circle(618,240,40+5*i);
delay(100);
}
for(i=1;i<5;i++)
{
line(5*i-5,0,5*i-5,479);
line(0,5*i-5,639,5*i-5);
line(639-5*(i-1),0,639-5*(i-1),479);
line(0,484-5*i,639,484-5*i);
delay(100);
}

settextjustify(CENTER_TEXT,CENTER_TEXT);
for(i=2;i<=9;i++)
{
settextstyle(TRIPLEX_FONT,HORIZ_DIR,5);
setcolor(i+6);
outtextxy(320,65+10*i,"TOURS & TRAVELS ");
delay(100);

setcolor(BLACK);
outtextxy(320,65+10*i,"TOURS & TRAVELS ");
setcolor(i+6);

settextstyle(DEFAULT_FONT,HORIZ_DIR,2);
outtextxy(320,240,"Project made by - ");
settextstyle(SMALL_FONT,HORIZ_DIR,6);
setcolor(2);
outtextxy(320,285,"Prashasti Mishra & Anuradha Dalmia ");
setcolor(i+6);

settextstyle(SMALL_FONT,HORIZ_DIR,6);
outtextxy(320,325,"A Complete Tours & Travels Management Package");
settextstyle(SMALL_FONT,HORIZ_DIR,6);
setcolor(CYAN);

outtextxy(450,380,"Press any key to continue..... ");

}
settextstyle(TRIPLEX_FONT,HORIZ_DIR,5);
setcolor(i+5);
outtextxy(320,65+10*i,"TOURS & TRAVELS ");
delay(500);
clearviewport();
delay(100);
setcolor(WHITE);

}

//if((s=getche())>=0);
settextjustify(LEFT_TEXT,TOP_TEXT);
settextstyle(DEFAULT_FONT,HORIZ_DIR,5);
} // END OF STARTER FUNCTION


void last(void)
{
float y1,a,b,i,axisx,axisy;
int c,z=1;
long float x;
int gdriver = DETECT, gmode, errorcode;
clrscr();
initgraph(&gdriver, &gmode, "c:\\bgi");
// setbkcolor(BLACK);
for(i=0;i<=2;i+=.5)
{
for (x=-12.3662/2;x<=12.3662/2;x+=0.01745)
{
a=-i*exp(-(x*x));
b=100*a;
c=b;
y1=p+c;
putpixel(318+x*100,y1,z);
delay(1);
}
z++;
}
axisx=37;axisy=12;
for(i=.5;i<=2;i+=.5)
{
gotoxy(axisx,axisy);
axisy-=3;
sound(750*i);
delay(200);
nosound();
}
axisx=2;axisy=17;
for(i=-3;i<=3;i++)
{
gotoxy(axisx,axisy);
axisx+=12;
sound(750*i);
delay(200);
nosound();
}
settextjustify(CENTER_TEXT,CENTER_TEXT);
for(i=2;i<=9;i++)
{
settextstyle(TRIPLEX_FONT,HORIZ_DIR,5);
setcolor(i+6);
outtextxy(320,210+25*i,"THANK YOU ");
}
getch();
} // END OF LAST FUNCTION.


//MAIN BODY OF THE PROGRAM
void main (void)
{
int ok,y;
int gdriver=DETECT,gmode,errorcode;
initgraph(&gdriver,&gmode,"");

starter();
do
{
initgraph(&gdriver,&gmode,"");
graphresult();
clrscr();
clearviewport();
setbkcolor(BLUE);
for(y=1;y<5;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\t\tENTER CHOICE\t\t\t\t\t";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
cout<<"\t\t\t HILL STATION ------> 1\n";
cout<<"\t\t\t SOUTHERN DESTINATION ------> 2\n";
cout<<"\t\t\t RELIGOUS PLACE ------> 3\n";
cout<<"\t\t\t SEA SIDE ------> 4\n";
cout<<"\t\t\t WILD LIFE SANTURIES ------> 5\n";
cout<<"\t\t\t SHOPPING CENTRES ------> 6\n";
cout<<"\t\t\t HISTORICAL PLACES ------> 7\n";
cout<<"\t\t\t EXPLORE EAST ------> 8\n";
cout<<"\t\t\t PROGRAMMER ------> 9\n";
cout<<"\t\t\t EXTRA ------> 10\n";
cout<<"\t\t\t EXIT ------> 11\n";
cout<<"--------------------------------------------------------";
cout<<"------------------------";
for(y=1;y<10;y++)
cout << "\t\t\t\t\t\t\t\t\t " << endl;

cout<<"\t\t\t Enter choice : ";
cin>>ok;
switch(ok)
{
case 1:hill();
break;
case 2:south();
break;
case 3:religion();
break;
case 4:seas();
break;
case 5:sancturies();
break;
case 6:shopping();
break;
case 7:historical();
break;
case 8:east();
break;
case 9:pass();
break;
case 10:extra();
break;
case 11:
break;
default:cout<<"INVALID CHOICE \n";delay(1500);break;
}
closegraph();
}
while (ok!=11);
last();
}

2006-11-19 22:42:45 · 5 answers · asked by Anonymous

find out the number of lines starting with alphabet A

2006-11-19 21:35:01 · 4 answers · asked by asawaridhande 1

2006-11-19 20:55:20 · 3 answers · asked by user 1

each user log on 1 client only

2006-11-19 20:49:33 · 2 answers · asked by Zari 1

2006-11-19 20:40:01 · 1 answers · asked by a_anshuman 1

2006-11-19 20:39:22 · 2 answers · asked by a_anshuman 1

please advice me a software or a process through photoshop that can help me.

2006-11-19 20:36:16 · 4 answers · asked by sahil_heartbeat2003 1

Hi...I need help on the EditPlus program...If anyone would have any websites that give any good tutorials on how to use it I.E. how to make pages, how to insert images, how to make links ect that would be very helpful and you would be helping me out a great deal....even if you have any quick tips about the program but would appreciate a website showing me or explaining to me how it works...

Thanks in advance to everyone who helps

2006-11-19 20:27:59 · 2 answers · asked by Shabran 2

I want to link the chapters of a book through a index that i have created in the first document. I have created buttons for each chapter. How can I link them up. I mean what is the simple code?

2006-11-19 20:21:29 · 2 answers · asked by STRANGER 2

what's the difference between "Process" and "Thread"?

2006-11-19 19:25:03 · 3 answers · asked by Spring 1

$db = mysql_connect("localhost", "root", "password");
mysql_select_db("mydb",$db);
$result = mysql_query("SELECT * FROM employees",$db);
if ($result === false) die("failed");
while ($fields = mysql_fetch_row($result)) {
for ($i=0, $max=sizeof($fields); $i < $max; $i++) {
print $fields[$i].' ';
}
print "\\n";
}

..... In $db = mysql_connect("localhost", "root", "password"); Will I encode as is or change "localhost" the name of the server, "root" the user, "password" the password or the given password...

2006-11-19 19:01:43 · 1 answers · asked by edwinbiasbas 1

what difference between convert functions and parse function. Which should we use Convert function(like Convert.Toint, Convert.Tobyte . . .) or int.parse, byte.parse

Ahmet Kaymaz
http://www.ahmetkaymaz.com
C#, Asp.Net, Ajax, Sql Server, Oracle

2006-11-19 18:59:40 · 1 answers · asked by Ahmet Kaymaz 1

seeking advice from net-community to help me out in geeting my 17-years old get educated in computer science.
Thaanks

2006-11-19 18:42:58 · 5 answers · asked by Peripatetic 2

This boy has completed his B.E (Mech Engg.) from chennai, I would request any good soul who can utilise his urge to develop a career in Desigining. He would like to join as a trainee.

He is currently working as a visting Professor in a Polytechnic College in Chennai.

Kindly do respond

2006-11-19 18:10:13 · 2 answers · asked by lhn 2

IM LOOKING FOR SOMETHING EXOTIC AND SEXY FOR MY WEB PAGE.

2006-11-19 17:49:47 · 4 answers · asked by classy_caramel74 1

I want graphics for my page...where can I find them? The kind I'm looking for are banners, pictures, blends, etc ..

2006-11-19 17:33:56 · 3 answers · asked by sooblyadoobly 2

the first project was installed to one computer... and I want to make a project to another computer... using LAN how can I make a link on the same fields... rather connect to its database?

2006-11-19 17:26:09 · 1 answers · asked by edwinbiasbas 1

2006-11-19 17:19:15 · 3 answers · asked by bill 2

We can construct a date object in java including year,month,day, hour,minutes ,seconds using the Date construtor ? whether is there any way to construct a Date object including the milliseconds ? ...

2006-11-19 17:07:04 · 2 answers · asked by Anonymous

If you have an e-mail address or IP address how can you find the address of the person?

2006-11-19 16:09:29 · 4 answers · asked by Kay 1

why do computer "geeks" accept the binary system when it comes to the programming of computers?? There are more effective ways that take less space and time to make a computer and it's programs work, what arethe computer "GODS" waiting for ???? or am I just the only one who sees this????

2006-11-19 16:06:51 · 5 answers · asked by eddy r 2

I've made it my personal goal to graduate in 2-3 semesters now that I have taken all my classes required for my major in computer programming (AS). Regardless, the question I have today is how different is the stuff in the real world, from the stuff in the class room? I would imagine the programs are larger and I would typically have to work as a team...but all the concepts would apply (get project, create algorithms, test algorithms, code project, debug, comment and rewrite, then write documentation) right?

What can I expect?

2006-11-19 15:33:47 · 2 answers · asked by D 4

Environments: SQL server 2000, .net 2.0
In normal case, i create a invoice then create detail invoice by the ID of newest record in invoice table. But if in the below situation, I need a solution. Can you help me?
1. User 1 create record A in invoice table.
2. User 2 create record B in the invoice table.
3. Then User create record C in detail invoice table by ID of newest record (B in this situation).
--> Wrong expectation.
I guess we should have these solutions, but which one is the best and is there some sol better?:
- Use @@Identify after create record in invoice table.
- Use customize ID.

2006-11-19 15:32:46 · 2 answers · asked by quoc_phan_logigear 1

Write a C program that compares two files and issues the message
file1 and file2 are identical
when the files are the same or issues the message
file1 and file2 : first difference in byte number ___.
when they are different. The names of the two files should appear as command line parameters.

2006-11-19 15:17:50 · 2 answers · asked by Shaina B 1

I've made alot of sites in my day, it's just that I don't know how to make sites that let people make a profile and design it. I need help!! So, don't be a coward and leave me with a site that is just.. lame. Give me some answers.

2006-11-19 15:17:29 · 4 answers · asked by Kendra 1

Write a function in C that takes 3 parameters: the address of a 2-dimensional array of type int, the number of rows in the array, and the number of columns in the array. Have the function calculate the sum of the squares of the elements. For example, for the array nums that is pictured as:
23 12 14 3
31 25 41 17
the call to the function might be
sumsquares ( nums, 2, 4 ) ;
and the value returned would be 4434. Write a short program to test the function.

2006-11-19 15:09:28 · 3 answers · asked by missbehavin288 1

fedest.com, questions and answers