*
**
***
****
*****
i need to make a triangle like this for a homework assignment
heres what i have so far
im stuck on this
i must use for loops...when i compile it all it does is end the program
#include <iostream>
using namespace std;
int main ()
{
int lines;
int spaces;
int dots ;
cout << "How many lines do you want in the picture?\n";
cin >> lines;
for ( lines; lines == 0; lines--){
for (spaces = lines - 1; spaces <= 0; spaces-- ){
cout << "_";
for (dots = 1; dots <= lines; dots++ ){
cout << '*';}
cout << endl;}}
return 0; }
please help thanks