Answers for "basic data types in c++ hackerrank solution"

C++
1

basic data types in c++ hackerrank solution

#include <iostream>
using std::cin;
using std::cout;
using std::endl;
using std::fixed;

int main() {
    int a; long b; char c; float d; double e;
    cin>>a>>b>>c>>d>>e;
    cout<<a<<endl;
    cout<<b<<endl;
    cout<<c<<endl;
    cout.precision(3);
    cout<<fixed<<d<<endl;
    cout.precision(9);
    cout<<fixed<<e<<endl;
    return 0;
}
Posted by: Guest on June-08-2020

Code answers related to "basic data types in c++ hackerrank solution"

Browse Popular Code Answers by Language