Dev-c++下‘stoi‘ was not declared in this scope解决办法
生活随笔
收集整理的這篇文章主要介紹了
Dev-c++下‘stoi‘ was not declared in this scope解决办法
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
在練習PAT時使用dev-C++寫代碼時,使用stoi函數發現提示
’stoi’ was not declared in this scope,
在網上找了許多方法
參考了 https://blog.csdn.net/pythontojava/article/details/86255144
和 https://blog.csdn.net/Joyceyang_999/article/details/87980155 的方法都試了一下還是會有這個問題,解決不了
這時候我想會不會是我dev-C++版本不行,
我使用的是免安裝版的Dev-cpp5.4.0,但是不知是什么時候下的,哪來的了,
因為PAT考場的環境是devc++5.10版本,然后我找到了5.10版本的安裝包 百度云鏈接: https://pan.baidu.com/s/1WKa8ryo5oAtl82EBfn6oLA
提取碼: 2333
,
安裝好之后,直接執行代碼還是會提示
’stoi’ was not declared in this scope,
然后我使用
https://blog.csdn.net/pythontojava/article/details/86255144 的方法在加上
-std=c++11
然后點確定,執行。問題解決
總結
以上是生活随笔為你收集整理的Dev-c++下‘stoi‘ was not declared in this scope解决办法的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: Vue 第三方集成之 Cesium
- 下一篇: jsp日期格式化显示