Making a pattern using void()
I am taking intro to c++ so this should be fairly simple for you c++ gurus. Here is an example of a program my professor wants me to write:
Enter number of lines: 4
Enter character: *
___*
__**
_***
****
(^ignore the underscores, the only way i know how to display it^)
This is what I have so far but I know i am wrong. Our professor gave us sort of a mini example so I tried my best to copy what he did but use what we are supposed to do, but i tried.
Code:
{
pattern void (pattern)
char ch;
int lines;
cout << "enter # of lines"
cin >>lines;
cout<< "Enter character"
cin >> ch;
for (intj=5; j>=5; ++j)
ch;
for (inti=lines; i<=lines; --lines)
}
Like I said, I KNOW i'm wrong and dont even know what the i, and j stand for :P. Point me in the right direction of more info and please help me as much as possible
Thanks in advance,
steve