各位大佬,有谁可以解答一下为什么这里会报错吗?
void value not ignored as it ought to be
#include<iostream>
#include<stack>
using namespace std;
int main()
{
stack <int> tempt;
tempt.push(1);
tempt.push(1);
//报错位置
int a=tempt.pop();
cout<<a;
return 0;
}