#GESP2214. [GESP]L4-202403-Q2214-S

[GESP]L4-202403-Q2214-S

第11题 如果文件 1.txt 中的内容如下,则执行下面 C++ 代码时,注释了 #### 那行代码所输出的 xx 的值为( )。

50 2024 3.16 I
love
GESP!
int main()
{
    ifstream fin;
    string line;
    int x;
    fin.open("1.txt", ios::in);

    for (int i = 0; i < 2; i++) {
        fin >> line;
        cout << line << endl;
    }
    fin >> x;
    cout << x << endl; //####
    
    cout << endl;
    return 0;
}

{{ select(1) }}

  • 55
  • 20242024
  • 33
  • 00