Deprecated: Array and string offset access syntax with curly braces is deprecated in /mnt/hep_web/hep_web/member/n-kota/dokuwiki/inc/init.php on line 542
====== ファイル・ディレクトリの存在確認 ======
----
stat("filename",&st) が0を返せばファイル(ディレクトリ)が存在、それ以外なら存在しない。
#include
...
struct stat st;
if( stat("filename",&st)==0 ){///// file exists
cout << "file exist." << endl;
}