Hi, Everybody.
After compiling below program i am getting error" prg2(distance with error),Please help me to resolve.
Thank you
#include<iostream.h>
#include<conio.h>
struct distance
{
int feet;
int inches;
};
distance length1,length2;
void prnsum(int distance11,distance12);
int main()
{
clrscr();
int distance,z;
cout<<"Enter length1:"<<"\n";
cout<<"Feet:";
cin>>length1.feet;
cout<<"\n"<<"Inches:";
cin>>length1.inches;
cout<<"\n"<<"\n"
<<"Enter length2:"<<"\n";
cout<<"Feet:";
cin>>length2.feet;
cout<<"\n"<<"Inches:";
cin>>length2.inches;
prnsum(length1,length2);
return 0;
cin>>z;
}
void prnsum(int distance11,distance12)
{
distance 13;
13.feet=11.feet+12.feet+(11.inches+12.inches)/12;
13.inches=(11.inches+12.inches)%12;
cout<<"\n"<<"\n";
cout<<"Total Feet:"<<13.feet<<"\n";
cout<<"Total Inches:"<<13.inches;
return;
}