여러 변수 출력하기
#include <iostream>
using namespace std;
int _tmain(){
int a = 10;
int b = 11;
int c = 12;
cout << a << ', ' << b << c //출력하고 싶은 변수를 << 로 각각 추가해주면 된다.
}
C++ 개념 더보기
'◼️C++' 카테고리의 다른 글
| [C++] 변수 선언 및 정의 (0) | 2023.08.31 |
|---|---|
| [C++] 자료형 (0) | 2023.08.31 |
| [C++] 문자열 데이터 std::string (0) | 2023.08.31 |
| [C++] Visual Studio 에서 추가로 사용하는 헤더파일 <stdafx.h> (0) | 2023.08.31 |
| [C++] Hello world 출력해보기 (0) | 2023.08.31 |