Comment detail

LL Golf Hole 6 - 10進数を2進数に基数変換する (Nested Flatten)
バッチで。(バッチの制限上、指定できる値は 0から2147483647まで。)
1
2
3
4
5
6
7
8
@echo off
setlocal
  set d=%1
  :_
    set /a m=d%%2,d/=2
    set t=%m%%t%
  if %d% gtr 0 goto :_
endlocal & echo %t%

Index

Feed

Other

Link

Pathtraq

loading...