• + 6 comments

    int main(){ int n, space, hash; scanf("%d",&n);

    for( int i = 0; i<n; i++)
    {
        space = (n-1)-i;
        hash = i+1; 
        while(space != 0)
        {
            printf(" ");
            space--;
        }
        while( hash!= 0 )
        {
            printf("#");
            hash--;
        }
        printf("\n");
    
    }
    return 0;
    

    }