Preview:
//1- (string) ---> (int)
stoi("String name");
 
//2- (int) ---> (string)
int n;
cin>>n;
String s = to_string(n);
cout<<s;
 
//3- (char) ---> (int)
String str;
cin>>str;
for(int i; str[i], i++){
  char ch = str[i]-'0';   //note:(str[i]-'0') to convert str[i] character to integer
  cout<<ch;
}
  
//3- (int) ---> (char)
int n;
cin>>n;
char ch = (char) n;
cout<<ch;
 
//4- (int) ---> (long long)
int a;
a = a*1LL;
 
//5- (double) ---> (int) && flooring number
double n = 7.99999999;
n = (int) n;
downloadDownload PNG downloadDownload JPEG downloadDownload SVG

Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!

Click to optimize width for Twitter