【发布时间】:2020-04-16 19:01:41
【问题描述】:
我有一段代码
#include <bits/stdc++.h>
using namespace std;
typedef long long ll ;
int main()
{
ios_base::sync_with_stdio(0);cin.tie(0);cout.tie(0) ;
int i, j;
i = j = 5;
j = i++ + (i*10);
cout<<i<<" "<< j <<" "<<i++;
}
c++ 17 的代码输出为:6 65 6 c++ 11 的代码输出为:7 65 6
为什么会有这样的差异?
【问题讨论】:
-
您使用的是什么编译器,带有什么标志?
标签: c++ c++11 c++17 postfix-operator