我有寫入在我的程序讀數據從一個文件的副本的陣列用於寫入
tabptr = fopen(argv[1],w+)
做argv [1] FILE對象,我需要從同一文件讀取,但我將如何創建一個指針,可以從argv [1]讀取而不是寫入的tabptr指針?或者我只是在想這個過程。
tabptr = fopen(argv[1],w+)
//tabptr writes to argv[1]...
//time to declare file to read from the same tabptr wrote to
FILE * tabptrStr = tabptr //how would i make tabptrStr readable?
tabptrStr = fopen(argv[1],"r") //or am i just overthinking this and this will accomplish my goal?
的argv [1]正是混淆了我,我是新的C,從C++