# Week 3 ###### tags: `C++` ## 語法補充 ### stdin, stdout, stderr standard input: 輸入流(預設keyboard) standard output: 輸出流(預設console) standard error: 錯誤流 ```cpp= freopen("in.txt", "r", stdin); freopen("out.txt", "w", stdout); ``` > "in.txt" / "out.txt" 檔案名稱 > "r" / "w" 模式 (read / write) ```cpp= cerr << "Hello!"; ``` ### substr ## 如何練習 * AC is NOT YOUR GOAL! LEARN! * No 水題 * 可靠的人寫什麼就寫什麼 * 解到沒有想法+3分鐘 * Take notes