RE: can't figure this out

new topic     » goto parent     » topic index » view thread      » older message » newer message

George Walters wrote:
> Bernie... run this
> 
> sequence screenTable, tmp
> 
> screenTable = {0,0,0,0,0,0,2,8}
> 
> 
> printf(1,"%d  %d\n",{screenTable[8],screenTable[7]})
> tmp = sprintf("%d",screenTable[8])&"."&sprintf("%d",screenTable[7])
> printf(1,"%4.2f\n",tmp)
> 
> tmp = gets(0)
>  

george:

Why are you using the sprintf() when you can do this

printf(1,"%d.%0.2d\n",{screenTable[8],screenTable[7]})


Bernie

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu