You are viewing a single comment's thread. Return to all comments →
#include<bits/stdc++.h> using namespace std; int main() { int a; long b; char c; float d; double e; cin>>a>>b>>c>>d>>e; cout<<a<<"\n"<<b<<"\n"<<c<<"\n"; cout<<fixed<<setprecision(3)<<d<<"\n"; cout<<fixed<<setprecision(9)<<e<<"\n"; return 0; }
And if you want same speed as printf and scanf add these two lines in main just before variable declaration
ios_base::sync_with_stdio(false); cin.tie(NULL);
Seems like cookies are disabled on this browser, please enable them to open this website
Basic Data Types
You are viewing a single comment's thread. Return to all comments →
Simple :-)
And if you want same speed as printf and scanf add these two lines in main just before variable declaration