Skip to main content

SuppposeSuppose I have an integer= 0123456789101112 integer = 0123456789101112. Now This Integer Can, this integer can be Convertedconverted into String By stringstreama string by the stringstream class.

Here is Codethe code in C++:

 #include <bits/stdc++.h> using namespace std; int main() { int n,i; string s; stringstream st; for(i=0;i<=12;i++) { st<<i; } s=st.str(); cout<<s<<endl; return 0; } 

Supppose I have an integer= 0123456789101112 . Now This Integer Can be Converted into String By stringstream class

Here is Code in C++

 #include <bits/stdc++.h> using namespace std; int main() { int n,i; string s; stringstream st; for(i=0;i<=12;i++) { st<<i; } s=st.str(); cout<<s<<endl; return 0; } 

Suppose I have integer = 0123456789101112. Now, this integer can be converted into a string by the stringstream class.

Here is the code in C++:

 #include <bits/stdc++.h> using namespace std; int main() { int n,i; string s; stringstream st; for(i=0;i<=12;i++) { st<<i; } s=st.str(); cout<<s<<endl; return 0; } 
Source Link

Supppose I have an integer= 0123456789101112 . Now This Integer Can be Converted into String By stringstream class

Here is Code in C++

 #include <bits/stdc++.h> using namespace std; int main() { int n,i; string s; stringstream st; for(i=0;i<=12;i++) { st<<i; } s=st.str(); cout<<s<<endl; return 0; }