Engineering notation no embed by nn

char*p,*q,s;main(e){for(;~scanf("%[0-9.]e%d\n",p=&s+99,&e);*q=0,puts(p)){for(;q=index(p,46),e;*q=46)e--<0?*--p=48,*q--=q[-1],e+=2:(*q++=q[!!strcat(p,"0")]);for(q=index(p,0);*--q==48;);*q-46&&q++;}}

Note that non-ascii characters in the above source code will be escaped (such as \x9f).

download

return to the top page