Hi all, I am a first year student at the university of South Africa. I am doing my degree via correspondence, thus no lectures. I am working through the prescribed book as best i can but they still assume a little bit of fore knowledge of programming which i don't have! Please tolerate me for asking what should probably be a very easy question for you all.

They want me to write a void function which does the following. A number is entered, eg 6 ant then the following should be the output;

#^^^^^^^^^#

^#^^^^^^^#^

^^#^^^^^#^^

^^^#^^^#^^^

^^^^#^#^^^^

^^^^^#^^^^^

I know that a 'for' loop is required to do this, but I cant figure out how many to nestle!?

The formula (2 * nrP - 2 * i - 1) is given as a hint where 'nrP' is the number of rows entered by the user for the function to use and 'i'

will be the row generated by the loop. I have no examples of this in my text book to refer to for help.

If someone could just steer me in the right direction it will already be a huge help.

PLEASE HELP!!

thanks