G
Gurikar
Hello,
ofstream ofs;
fun(char* str)
{
ofs<<str<<endl;
}
void main()
{
int i=0;
....
....
if(i)
{
ofs.open("text.txt");
fun("heih0");
}
else
{
// Here iam not opening file
fun("heih0");
}
}
In the above code, in else condition iam not opening file, but still
calling fun(), What happens here???
Regards
ofstream ofs;
fun(char* str)
{
ofs<<str<<endl;
}
void main()
{
int i=0;
....
....
if(i)
{
ofs.open("text.txt");
fun("heih0");
}
else
{
// Here iam not opening file
fun("heih0");
}
}
In the above code, in else condition iam not opening file, but still
calling fun(), What happens here???
Regards