본문 바로가기

Algorithm

백준(baekjoon)(BaekJoon)코딩 2438번:별찍기-1 답

반응형

#include <iostream>
using namespace std;
int main(){
int n;
    cin>>n;
    for(int i=1;i<n+1;i++)
    {
        for(int j=0;j<i;j++)
        { cout<<"*";}
        cout<<"\n";
}
}