반응형 줄바꿈1 C++ iomanip 헤더, 소수점 자리 출력 fixed #include 를 포함시키면 setprecision(자리수)를 사용할 수 있다. 또한 fixed를 사용하여 원하고자 하는 자리수 까지 출력할 수 있다. #include #include using namespace std; int main(){ double a = 1.8888888888; //소수점 3번째 자리에서 반올림 cout 2021. 7. 2. 이전 1 다음 반응형