what is the meaning of fin.open function if i use it in the coding?
There is no such function as fin.opn
I suppose you mean that fin is a ifstream[or ofstream] object.
Files in c++ are treated as streams. ifstream is input stream and ofstream is for output. These objects are used while reading or writing to a file. the are under the fstream header and i suggest you look that up too.
open is a function used to open a file.
The syntax is like this
void open ( const char * filename, ios_base::openmode mode = ios_base::in );
this is for ofstream object
void open ( const char * filename, ios_base::openmode mode = ios_base::out );