More actions
imported>장용운 ({CREATE}) |
No edit summary |
||
| (4 intermediate revisions by one other user not shown) | |||
| Line 43: | Line 43: | ||
return 0; | return 0; | ||
} | } | ||
= 결과 = | |||
[[:File:binggeul.png|binggeul.png]] | |||
= 잡담 = | |||
* 이 양식으로 구현하면 쉽습니다 - [[장용운]] | |||
* 별찍기 코드가 더욱 참신해져서 돌아왔군요 - [[박인서]] | |||
---- | |||
[[새싹교실/2016/리바이반/0509]] | |||
[[새싹교실/2016/리바이반]] | |||
Latest revision as of 11:29, 9 May 2016
참고코드
#include <stdio.h>
#pragma warning(disable:4996)
int main(void) {
const char star = '*';
const char space = ' ';
char c;
int rows = 15;
int cols = 14;
for (int i = 0; i < rows; i++) {
for (int j = 0; j < cols; j++) {
c = space;
if (/* 작성하세요 */) {
if (/* 작성하세요 */)
c = star;
}
else if (/* 작성하세요 */) {
if (/* 작성하세요 */)
c = star;
}
else if (/* 작성하세요 */) {
if (/* 작성하세요 */)
c = star;
}
else {
if (/* 작성하세요 */)
c = star;
}
printf("%c%c", c, c);
}
printf("\n");
}
return 0;
}