🔒 Closed Programming help po.may premyo sa makakasagot

Status
Not open for further replies.

alliit

Grasshopper
Create a program that accepts any number.create a triangle whose height is as tall as the inputted number. sample output: enter number: 3
***
**
*
 
madali lng yan... ano language? c at java lang alam ko.

ito algo ohh
for(i=n;i>0;i--){ //n = input
print("*");
for(j=0;j<i-1;j++){
print("*");
}
print("\n");
}
 
Status
Not open for further replies.

About this Thread

  • 12
    Replies
  • 1K
    Views
  • 5
    Participants
Last reply from:
alliit

Trending Topics

Online now

Members online
1,269
Guests online
4,980
Total visitors
6,249

Forum statistics

Threads
2,305,640
Posts
29,166,967
Members
1,195,388
Latest member
theginnyman
Back
Top