-
-
Save parzibyte/af303a6906140b7e61686d72161e79e8 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <sstream> | |
std::string enteroACadena(int entero) | |
{ | |
std::string numeroComoCadena = ""; | |
std::stringstream ss; | |
ss << entero; | |
ss >> numeroComoCadena; | |
return numeroComoCadena; | |
} | |
int main() | |
{ | |
std::string convertido = enteroACadena(89); | |
std::cout << convertido + "\n"; | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment