Your abc struct itself is POD, so you can write/read it fairly easily.
But your y array is an array of pointers, which is not the data itself.
Your file needs to have the individual abc struct data stored in it. You can't get around that. But if you wish to store that data in your pointer array, you probably need to dynamically allocate each element so that each y[i] points to the dynamically loaded element.
Why is y an array of pointers to abc, and not an array of abc?
If y is just an array of abc, then you can read/write this to a file using just a single read()/write(). The size of data to read/write is just sizeof(y).
If y is really an array of pointers, then you'll need to iterate the array, de-reference each pointer to get the abc type data and then write this data to the file. For reading, iterate the array, obtain new memory for each element and then read the data from the file to this memory. The size of each element to read/write is sizeof(abc).
NOTE that is is NOT a text file - but a binary file.