Re: I have a problem help me
Hello !!
By to Italy.
Luca Mannocci
Alle 18:53, giovedì 10 novembre 2005, Avik Chatterjee ha scritto:
> Hello,
> I'm avik.I have been facing a problem in a
> typical Java program.The problem is...
>.....
that'll print the following:
*
***
*****
*******
*********
***********
> I have done this but not more
class star
{
public static void main(String args[])
{
int b = 10;
int d = b/2;
for(int i=0;i<=d;i++) {
int ma=d-i;
int mb=d+i;
for(int j=0;j<=b;j++)
{
if( j >= ma && j <= mb)
System.out.print("*");
else
System.out.print(" ");
}//End 2^ loop
System.out.println();
}//End 1^ loop
}
> please help me.
>
>
>
> __________________________________________________________
> Enjoy this Diwali with Y! India Click here
> http://in.promos.yahoo.com/fabmall/index.html
Reply to: