if i have an array such as:

unsigned short m_usArray[1000];

and i fill it up with unsigned shorts, is there away i can write the entire array to a file with just one command instead of doing something like:

ofstream ("file.txt");
for( int i = 0; i < 1000; i++ )
{
fout << m_usArray[i];
}
fout.close();

?

cheers, bigdaz