I had created this code, and a lot is missing from it, the input value is "h=6" and "v=4"
it's output is:
*
*
*
*******
Code:#include <stdio.h> #include <conio.h> main() { int h,h1,v,v1; printf("Enter horizontal value:\n"); scanf("%d",&h); printf("Enter vertical value:\n"); scanf("%d",&v); h1=0; v1=0; while(v1<=v) { printf("\n*"); v1++; while(h1<=h) { printf("*"); h1++; } } getch(); }
the output supposed to be is an a square box of asterisk with an a 6X4 field. It should look like this:
without the dashes
******
*-----*
*-----*
******
Can anyone point me to the right direction here!!!
I'm still new to c programming, barely a month ago.
Anyone can give me a clue on this! Little and big help will be graciously accepted.
thnx anyone in advance!