adjust

A.T.Hofkamp hat at se-126.se.wtb.tue.nl
Tue Apr 24 07:12:56 EDT 2007


On 2007-04-24, saif.shakeel at gmail.com <saif.shakeel at gmail.com> wrote:
> Hi,
>      How do i right adjust my output using python.I need a output
> something like this:
> DID=      0x01,0x02,0x03,0x05,0x06,0x07,0x2B,0x30,0x31,0x4D,0x4E,
> 0x51,0x52,0x53,0x55,
> minlength=   3,   3,   4,   2,  10,  10,  40,   2, 150,   4,   1,
> 2,   2,   1,   2,   1,   6,   3,  17,   1,
> maxlength=   3,   3,   4,   2,  10,  10,  40,   2, 150,   4,   1,
> 2,   2,   1,   2,  30,   6,   3,  17,  20
>
>     I am printing from a list, and the values shld print below each id
> like shown.
>                  Thx

Collect the data to print in rows underneath each other in a list for each
column, decide how wide each column should become, and finally, print out each
line using the computed widths.

Albert



More information about the Python-list mailing list