Urgent !!

how can do a program that will draw a square like
****
* *
* *
****
where you input N and the sides are N x N (where N>=2 and N<=50)

Using only FOR IF WHILE DO-WHILE and SWITCH
pls help
Last edited on
There are three parts to this.
1. How do you output this:
****

2. How do you output this:
*  *

and 3. how to control the appropriate output of either (1) or (2) as required.

Broken down into stages, it isn't so hard, though there are probably several different ways to tackle it.

Last edited on
Can someone do an example
Show us the code you've got so far.
The tutorial http://www.cplusplus.com/doc/tutorial/ might help you
Topic archived. No new replies allowed.