can anyone answer this question?

You are to write a C++ language program that:
1. Reads in the size of a square from the screen;
2. Prints a hollow square of that size out of “-“, “|” and blanks on screen;
3. Prints the same hollow square onto a text file.
Your program should work for squares of all side sizes between 1 and 20.
Output:
If your program reads a size of 5, it should produce output the same as that illustrated below:
Hollow Square Program
++++++++++++++++++++++++++++++++
-----
| |
| |
| |
-----
++++++++++++++++++++++++++++++++
End of Program Execution

>>can anyone answer this question?
Yes I can do it, but won't.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.