The perl module Graphics::Simple might be able to help you.

Found on CPAN.

--jms


On May 5, 2008, at 9:22 AM, Rodrigo Tavares wrote:

Hello,

I need create a square using a single number, but I don't know how to create the sides.

I have to create this:

****
*  *
*  *
****

My code is below :

print "Enter with number:";
chomp ($number = <STDIN>);

my @array = ();

$cont = 0;

while ($numero > $cont)
{
        $array[$cont]="*";
        $cont++;
}

print @array;
print "\n";
print @array;
print "\n";

How I can to show the arrar like sides ?

[]'s

Faria


Abra sua conta no Yahoo! Mail, o único sem limite de espaço para armazenamento!
http://br.mail.yahoo.com/

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/




--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/


Reply via email to