본문 바로가기
category/백준 알고리즘 c++

백준 알고리즘 10172번 개 c++

by 자운대고라니 2020. 12. 3.
반응형

요약 : 예제 출력 1처럼 개 모양 출력, "를 출력할땐 앞에 \를 붙여줘야함 ex) cout << "\"" << endl -> "출력


소스코드

1
2
3
4
5
6
7
8
9
10
11
12
#include <iostream>
 
using namespace std;
 
int main(void) {
    cout << "|\\_/|" << endl;
    cout << "|q p|   /}" << endl;
    cout << "( 0 )\"\"\"\\" << endl//"를 출력하려면 \"를 쓰면 댐
    cout << "|\"^\"`    |" << endl;
    cout << "||_/=\\\\__|" << endl;
    return 0;
}
cs

정답 확인

 

반응형

댓글