check this program beneath.......
\\program to fin integere part and fractional part of given real number...
cout<<"enter any real number:";
cout<<"integer part is:"<<intpart;
cout<<"\nfraction part is:"<<fracpart;
void intfrac(float n,float& intp,float& fracp)
i was doing this program in order to implement the concept of passing the
value by reference in functions.
this can be done easily by using type casting,bt i was trying this logic......
but compiler is showing some errors (fracp=n%1;)in this line.
can someone help me with it........plz
also if someone can give some good points about the diff. between pass by reference
and pass by value......