mirror of
https://hub.njuu.cf/TheAlgorithms/C-Plus-Plus.git
synced 2023-10-11 13:05:55 +08:00
MSVC does not know cstring-use string-for toString
(cherry picked from commit fe9d2b9bc6
)
This commit is contained in:
parent
64c8bf38bd
commit
a15b5c5a9b
@ -1,6 +1,13 @@
|
|||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
||||||
|
#ifdef _MSC_VER
|
||||||
|
// Required to compile std::toString function using MSVC
|
||||||
|
#include <string>
|
||||||
|
#else
|
||||||
|
#include <cstring>
|
||||||
|
#endif
|
||||||
|
|
||||||
int main() {
|
int main() {
|
||||||
int num;
|
int num;
|
||||||
std::cout << "Enter number = ";
|
std::cout << "Enter number = ";
|
||||||
|
Loading…
Reference in New Issue
Block a user