若有charfname[]="outfile.dat";,则为写而打开文本文件outfile.dat正确写法是()
A:fopen(“outfile.dat,"w")
B:fopen(outfile.dat,"w")
C:fopen(fname,"w")
D:fopen("fname","w")
出自:计算机科学