Hi!

Let's say I would like to print equals sign $x number of times. In
Python I could do this:

>>> x=5
>>> print("=" * x)
=====
>>>

..or for example, in Bash I could do "for i in $(seq $x); do echo -n
=; done; echo". What is the most elegant way to do this in SLAX? At
the moment I solved it with this:

var $sout = jcs:printf("%.*s", $separator,
    "==========================================" _
    "==========================================" _
    "==========================================" _
    "==========================================");

It works, because I know, that $separator is less than 168 characters
long, but maybe there is a better solution.


thanks,
Martin
_______________________________________________
juniper-nsp mailing list [email protected]
https://puck.nether.net/mailman/listinfo/juniper-nsp

Reply via email to