본문으로 건너뛰기
더시드위키
최근 변경
최근 토론
도구 모음
틀
계산기2
(r262판 RAW)
보기
RAW
역사
[[분류:냥]][[분류:계산용 틀]][Include(틀:상세 내용, 설명대상=원본, 문서명=틀\:구 계산기2)][Include(틀:상세 내용, 설명대상=떼어낸 계산기, 문서명=틀\:계산기2-1)]{{{#!wiki style="display: none;" ##디버그용 if 문법 ("문자열" 값으로 정의해야 합니다.) {{{#!if a= ,b=, f= }}} ##== 변수 설명 == '''as''' : "a" value to string; '''bs''' : "b" value to string; '''al''' : "a" string length (integer); '''bl''' : "b" string length (integer) '''ad''' : "a" decimal point (integer); '''bd''' : "b" decimal point (integer); '''au''' : --gold-- "a" upper value (string→integer); '''bu''' : "b" upper value (string→integer); '''ab''' : "a" below value (string→integer); '''bb''' : "b" below value (string→integer); '''ap''' : "a" # of places of decimal (for addition or subtraction); '''ac''' : a '''c'''onstant of "a" for division (integer); '''bp''' : "b" # of places of decimal (for addition or subtraction); '''bc''' : a '''c'''onstant of "b" for division (integer); 0.303과 0.0303은 다른 수이므로 자리수가 다름을 표시할 용도 '''ru''' : "result" upper value (integer→string); '''rb''' : "result" below value (integer→string); '''rp''' : "result" # of places of decimal (integer); '''rs''' : "result" suprerior value (integer→string); '''ri''' : "result" inferior value (integer→string); '''i''' : index; '''tu''' : temporary value 1 (integer); '''tv''' : temporary value 2 (integer); '''tw''' : temporary value 3 (integer); '''tx''' : temporary value 4 (integer→string); '''ty''' : temporary value 5 (integer); '''tz''' : temporary value 6 (integer); '''pd''' : padding with zeros. (string) '''ps''' : pass (logical); '''ts''' : --not about gender-- test (logical) ; '''br''' : break (logical); '''ea''' : error code about "a" (integer); '''eb''' : error code about "b" (integer); '''wa''' : warning code about "a" (integer); '''wb''' : warning code about "b" (integer); '''ma''' : message about "a" (string); '''mb''' : message about "b" (string); '''tm''' : temporary string, or transaction message (string); '''tn''' : temporary string 2 (string); '''ns''' : negative sign for multiplication and division (string); ##== 초기화 == 값을 미리 정의하여 초기화합니다. 중간에 --장난으로-- 계산에 사용되는 변수에 값을 부여한 채로 include 하더라도 이를 무시합니다. {{{#!if this.as=a.toString(), this.bs=b.toString(), this.rs=0+0, this.ru=0+0, this.rb=0+0, this.ri=0+0, this.rp=0+0, this.i=0+0, this.tu=0, this.tv=1+0, this.tw=0, this.tx=0, this.ty=0, this.ea=0+0, this.eb=0+0, this.wa=0+0, this.wb=0+0, this.ps=false, this.ts=false, this.br=false, this.ns="", this.ma="", this.mb="", this.tm="", this.tn="", this.pd="000000000000000000" }}}{{{#!if this.al=as.length, this.bl=bs.length, this.ad=as.indexOf("."), this.bd=bs.indexOf(".") }}}{{{#!if ad!=-1 소수점이 발견되는 자리 번호가 ad이므로 ad+1번에 해당되는 자리부터 끝까지 표기합니다. {{{#!if this.au=as.substr(0,ad), this.ab=as.substr(ad+1, al-ad-1), this.ap=ab.length }}}{{{#!if (au=="")||(au=="-")||(au=="+") .12345 식으로 또는 -.12345 식으로 기입할 경우 upper 값을 0으로 부여합니다. {{{#!if au="0" }}}}}}}}}{{{#!if ad==-1 소수점이 존재하지 않을 경우 au 문자열 길이값을 ad로 정의합니다. au의 마지막 문자열 index는 ad-1이 됩니다. {{{#!if this.au=as, ab="", ap=0+0, ad=au.length }}}}}}{{{#!if bd!=-1 {{{#!if this.bu=bs.substr(0,bd), this.bb=bs.substr(bd+1, bl-bd-1), this.bp=bb.length }}}{{{#!if (bu=="")||(bu=="-")||(bu=="+") {{{#!if bu="0" }}}}}}}}}{{{#!if bd==-1 {{{#!if this.bu=bs, bb="", bp=0+0, bd=bu.length }}}}}} ##== 유효성 검사 == the seed에서 지원되는 long(integer)가 unsigned였으면 1844경까지 가서 충분히 19자리로 놀 수 있었는데, signed long이므로 922경까지 가능한 공간에서 18자리로 잘라내기를 합니다. (소수점 위 최대 18자리, 소수점 아래 최대 18자리) (반점(,)을 자동적으로 생략하고 들어가는 것은 나중에 생각하겠습니다.) {{{#!if (as!=null)&&(bs!=null) a와 b 모두 입력되었을 때, br와 ts 변수를 이용하여 순차적으로 검사를 진행합니다. 도중 문제가 있으면 (br를 true로 반환하고) 오류 코드를 내도록 만듭니다. a를 먼저 보며, 소수점 윗부분을 먼저 본 다음 소수점 아랫부분을 봅니다. 변수 tm와 tn을 가져와 유효성 검사를 실행합니다. 먼저 소수점을 2개 이상 입력했음이 탐지된다면 오류코드 5번(이중 소수점 표기)을 반환합니다. 소수점을 입력하면 indexOf와 lastIndexOf는 서로 다른 값을 가리키게 됩니다. 소수점을 입력하지 않았을 경우 indexOf와 lastIndexOf는 -1로 서로 같은 값을 가리키게 됩니다. {{{#!if ts=(as.indexOf(".")==as.lastIndexOf(".")), }}}{{{#!if !ts&&!br {{{#!if br=true, ea=5 }}}}}} 문제가 없으면 au를 tm으로 복제하고 검사를 계속 합니다. 앞자리가 마이너스(-)일 경우 이를 잘라냅니다. {{{#!if ts&&!br {{{#!if tm=au, tm[0]==45 {{{#!if tm=tm.substr(1) }}}}}} 소수점 윗자릿수가 넘치면 오류코드 1번(오버플로)를 반환합니다. {{{#!if ts=(tm.length<=18) }}}}}} {{{#!if !ts&&!br {{{#!if br=true, ea=1 }}}}}} 의도적으로 00을 적어놓았을 수 있으므로 tm 앞에 숫자 1을 더 붙인 다음, 이를 값으로 바꾼 다음 다시 텍스트 값으로 바꾼 문자열을 tn으로 정의합니다. 중간에 숫자가 아닌 문구가 들어갔다면 숫자가 아닌 문구가 들어간 부분부터 값이 잘려 나오게 됩니다. 숫자가 아닌 문구를 섞어넣었음이 탐지될 경우 오류코드 6번(소수점 윗자리 오류)을 반환합니다. (반점(,)도 걸릴 수 있습니다.) {{{#!if ts&&!br {{{#!if tm="1"+tm, tn=+tm, tn=tn.toString(), ts=(tm==tn) }}}}}} {{{#!if !ts&&!br {{{#!if br=true, ea=6 }}}}}} 소수점 아래 부분을 검사합니다. 앞에서 소수점 개수를 검사했으므로 소수점 아래 부분에 점(.)이 더 이상 나올 수 없습니다. 소수점 아래 입력한 자릿수가 19자리를 넘어가면 오류 대신 경고코드 1번(소수점 아래 자릿수 너무 많음)을 반환하고 소수점 아래 자릿수를 최대 18자리로 잘라냅니다. (이하 이상한 문구를 섞어도 이를 계산에 넣지 않게 됩니다.) {{{#!if ts&&!br {{{#!if ab.length>=19 {{{#!if wa=1, ab=ab.substr(0,18), ap=18 }}}}}} 앞에서 소수점 아래 자릿수를 18자 이하로 줄였습니다. 문자열에서 자릿수에 해당하는 index가 비어있다면 해당 문자열의 주소값은 null이 나옵니다. (예:"테스트"[3]==null) 숫자는 문자열 각 자릿수 문자열의 유니코드 값이 null이 아닌 이상 48 이상 57 이하이며, 이를 이용하여 소수점 아래 18자리에 대해 유효성 검사를 합니다. {{{#!if ts=(((ab[0]==null)||((ab[0]>=48)&&(ab[0]<=57)))&&((ab[1]==null)||((ab[1]>=48)&&(ab[1]<=57)))&&((ab[2]==null)||((ab[2]>=48)&&(ab[2]<=57)))&&((ab[3]==null)||((ab[3]>=48)&&(ab[3]<=57)))&&((ab[4]==null)||((ab[4]>=48)&&(ab[4]<=57)))&&((ab[5]==null)||((ab[5]>=48)&&(ab[5]<=57)))&&((ab[6]==null)||((ab[6]>=48)&&(ab[6]<=57)))&&((ab[7]==null)||((ab[7]>=48)&&(ab[7]<=57)))&&((ab[8]==null)||((ab[8]>=48)&&(ab[8]<=57)))&&((ab[9]==null)||((ab[9]>=48)&&(ab[9]<=57)))&&((ab[10]==null)||((ab[10]>=48)&&(ab[10]<=57)))&&((ab[11]==null)||((ab[11]>=48)&&(ab[11]<=57)))&&((ab[12]==null)||((ab[12]>=48)&&(ab[12]<=57)))&&((ab[13]==null)||((ab[13]>=48)&&(ab[13]<=57)))&&((ab[14]==null)||((ab[14]>=48)&&(ab[14]<=57)))&&((ab[15]==null)||((ab[15]>=48)&&(ab[15]<=57)))&&((ab[16]==null)||((ab[16]>=48)&&(ab[16]<=57)))&&((ab[17]==null)||((ab[17]>=48)&&(ab[17]<=57)))) }}}}}} 소수점 아래 자리에 입력한 부분이 문제가 있으면 오류코드 7번(소수점 아랫자리 오류)를 반환합니다. {{{#!if !ts&&!br {{{#!if br=true, ea=7 }}}}}} 이와 같은 방법으로 b도 bu를 tm으로 복제하는 과정을 포함하여 유효성 검사를 실행합니다. 오류코드는 동일합니다. a와 b를 각각 진단해야 하므로 br를 false로 초기화합니다. {{{#!if br=false, ts=(bs.indexOf(".")==bs.lastIndexOf(".")) }}}{{{#!if !ts&&!br {{{#!if br=true, eb=5 }}}}}} {{{#!if ts&&!br {{{#!if tm=bu, tm[0]==45 {{{#!if tm=tm.substr(1) }}}}}}{{{#!if ts=(tm.length<=18) }}}}}}{{{#!if !ts&&!br {{{#!if br=true, eb=1 }}}}}} {{{#!if ts&&!br {{{#!if tm="1"+tm, tn=+tm, tn=tn.toString(), ts=(tm==tn) }}}}}}{{{#!if !ts&&!br {{{#!if br=true, eb=6 }}}}}} {{{#!if ts&&!br {{{#!if bb.length>=19 {{{#!if wb=1, bb=bb.substr(0,18), bp=18 }}}}}}{{{#!if ts=(((bb[0]==null)||((bb[0]>=48)&&(bb[0]<=57)))&&((bb[1]==null)||((bb[1]>=48)&&(bb[1]<=57)))&&((bb[2]==null)||((bb[2]>=48)&&(bb[2]<=57)))&&((bb[3]==null)||((bb[3]>=48)&&(bb[3]<=57)))&&((bb[4]==null)||((bb[4]>=48)&&(bb[4]<=57)))&&((bb[5]==null)||((bb[5]>=48)&&(bb[5]<=57)))&&((bb[6]==null)||((bb[6]>=48)&&(bb[6]<=57)))&&((bb[7]==null)||((bb[7]>=48)&&(bb[7]<=57)))&&((bb[8]==null)||((bb[8]>=48)&&(bb[8]<=57)))&&((bb[9]==null)||((bb[9]>=48)&&(bb[9]<=57)))&&((bb[10]==null)||((bb[10]>=48)&&(bb[10]<=57)))&&((bb[11]==null)||((bb[11]>=48)&&(bb[11]<=57)))&&((bb[12]==null)||((bb[12]>=48)&&(bb[12]<=57)))&&((bb[13]==null)||((bb[13]>=48)&&(bb[13]<=57)))&&((bb[14]==null)||((bb[14]>=48)&&(bb[14]<=57)))&&((bb[15]==null)||((bb[15]>=48)&&(bb[15]<=57)))&&((bb[16]==null)||((bb[16]>=48)&&(bb[16]<=57)))&&((bb[17]==null)||((bb[17]>=48)&&(bb[17]<=57)))) }}}}}}{{{#!if !ts&&!br {{{#!if br=true, eb=7 }}}}}}}}} ##== 2차 초기화 == 입력한 소수점 아래에 입력한 값을 정리합니다. 이에 따라 ap, bp값도 다시 조정됩니다. {{{#!if (ap>9)&&(ab.substr(ap-9,9)=="000000000") {{{#!if ab=ab.substr(0,ap-9), ap=ap-9 }}}}}} {{{#!if (ap>4)&&(ab.substr(ap-4,4)=="0000") {{{#!if ab=ab.substr(0,ap-4), ap=ap-4 }}}}}} {{{#!if (ap>2)&&(ab.substr(ap-2,2)=="00") {{{#!if ab=ab.substr(0,ap-2), ap=ap-2 }}}}}} {{{#!if (ap>2)&&(ab.substr(ap-2,2)=="00") {{{#!if ab=ab.substr(0,ap-2), ap=ap-2 }}}}}} {{{#!if (ap>1)&&(ab.substr(ap-1,1)=="0") {{{#!if ab=ab.substr(0,ap-1), ap=ap-1 }}}}}} {{{#!if (bp>9)&&(bb.substr(bp-9,9)=="000000000") {{{#!if bb=bb.substr(0,bp-9), bp=bp-9 }}}}}} {{{#!if (bp>4)&&(bb.substr(bp-4,4)=="0000") {{{#!if bb=bb.substr(0,bp-4), bp=bp-4 }}}}}} {{{#!if (bp>2)&&(bb.substr(bp-2,2)=="00") {{{#!if bb=bb.substr(0,bp-2), bp=bp-2 }}}}}} {{{#!if (bp>2)&&(bb.substr(bp-2,2)=="00") {{{#!if bb=bb.substr(0,bp-2), bp=bp-2 }}}}}} {{{#!if (bp>1)&&(bb.substr(bp-1,1)=="0") {{{#!if bb=bb.substr(0,bp-1), bp=bp-1 }}}}}} 유효성 검사에 쓰인 tm과 tn 값을 빈 문자열 값으로 초기화합니다. {{{#!if tm="", tn="" }}} ##== 덧셈, 뺄셈 == 덧셈과 뺄셈 계산과정을 적어봅니다. {{{#!if (f=="+")||(f=="-") a과 b의 소수점 윗부분은 정수이므로 쉽게 계산할 수 있습니다. {{{#!if f=="+" {{{#!if ru=(+au)+(+bu) }}}}}} {{{#!if f=="-" {{{#!if ru=(+au)-(+bu) }}}}}} a와 b 모두가 정수이면 ap==0, bp==0이 되며, 이런 경우에는 소수점 아래 자릿수를 검산할 필요가 없습니다. a와 b 중 소수점 아래 자릿수가 있는 수가 있을 때에만 소수점 윗자리의 계산값이 얼마가 나오느냐를 보면서 소수점 아래의 자릿수를 정리하는 과정이 의미가 있습니다. {{{#!if (ap>0)||(bp>0) 만약 소수점 아래를 계산한다면 자릿수를 똑같이 맞춰야 의미가 있으므로, 자릿수가 다른 경우 자릿수가 같게 만드는 과정을 먼저 거칩니다. 이를테면 a의 소수점 자릿수가 b의 소수점 자릿수보다 많으면 b뒤에 0을 더 추가하는 방식으로 변경합니다. b 자체가 정수여도 앞에 (소수점이 없을 경우) 이미 bb="", bp=0+0으로 초기화했으므로 동작될 것입니다. 소수점 아래 최대 18자리까지의 수를 취급하므로 최대 18칸 차이가 나게 됩니다. ○○○○○○○○○□□□□○○□□○ 과 같이 9칸, 4칸, 2칸, 2칸, 1칸씩 차이가 나면 그 정도를 보정하게 됩니다. ap>bp에서 ap-bp>0이 됩니다. ap-bp는 곧 ap가 bp보다 몇 칸만큼 더 많은지를 나타냅니다. {{{#!if ap>bp {{{#!if bp=ap, bb+=pd }}}{{{#!if bb=bb.substr(0,ap) }}}}}} 반대로 b의 소수점 자릿수가 많은 경우도 있습니다. {{{#!if bp>ap {{{#!if ap=bp, ab=ab+pd }}}{{{#!if ab=ab.substr(0,bp) }}}}}} 위의 과정을 거치게 되면 소수점 아래 최대 자릿수를 똑같이 맞춘 상태에서 계산하게 되므로 ap==bp가 됩니다. a가 음수인 경우 소수점 아래 값은 순 숫자만 표기된 상태이므로 양수 취급으로 되지 않게 소수점 아래 값인 ab에 음수 표기를 남깁니다. {{{#!if as[0]==45 {{{#!if ab="-"+ab }}}}}} 마찬가지로 b가 음수인 경우 b의 소수점 아래 값은 음수이므로 소수점 아래 값인 bb에 음수 표기를 남깁니다. 10을 소수점 아래 자릿수만큼 제곱한 값으로 저장합니다. {{{#!if bs[0]==45 {{{#!if bb="-"+bb }}}}}} 이때 rb를 계산합니다. {{{#!if f=="+" {{{#!if rb=(+ab)+(+bb) }}}}}} {{{#!if f=="-" {{{#!if rb=(+ab)-(+bb) }}}}}} 소수점 아래끼리 더한 자릿수가 얼마나 되는지 보기 위해 rb를 문자열로 바꿉니다. 이 때 rb가 0이 아닐 경우에만 문자열로 변환합니다. {{{#!if (+rb>0)||(+rb<0) {{{#!if this.rb=rb.toString() }}} 문자열로 된 rb의 길이를 rp로 정의합니다. {{{#!if this.rp=rb.length }}} }}} rb가 음수이면 rb의 첫번째(0번 index)의 문자열에는 마이너스(-)가 들어갑니다. 이 때는 rp를 rb의 마이너스 문자열을 세지 않은 자릿수가 되도록 앞에서 정의했던 rb.length에서 1만큼 줄여 정의합니다. ap, bp는 마이너스를 붙이기 전에 값이 고정되어 있으므로 rp처럼 줄일 필요가 없습니다. {{{#!if rb[0]==45 {{{#!if rp=rp-1 }}}}}} ru값이 어떤지 보고 각 경우 rb값이 어떠한가에 따라 rb만 정리하거나 rb와 ru 모두 정리합니다. 중복 처리를 막기 위해 초기화된 ps 변수 하나를 가져옵니다. 소수점 아래 값의 부호와 소수점 위의 값의 부호가 서로 다른 경우 계산을 하기 위해 값을 하나 정의합니다. {{{#!if tv=+(("1"+pd).substr(0,ap+1)) }}} Case 1 : ru가 0보다 큰 경우 ru는 정수이므로 ru가 0보다 크면 곧 ru는 1 이상의 정수이며, 1 이상이면 a+b 또는 a-b가 양수+음수 꼴이 되더라도 소수점 아래 정리를 하면 됩니다. rb를 정리하는 과정에서 ru에서 1을 빌려오거나 ru에 1이 더해질 수도 있습니다. 앞에서 rb를 string으로 바꿨으므로 +rb를 다룹니다. {{{#!if ru>0 Case 1-1 : rb가 0 이상인 경우 {{{#!if (+rb>=0)&&!ps rb가 소수점 아래 자릿수를 초과하여 소수점 위의 수를 계산하게 생겼다면 ap=bp인 상황에서 rp>ap가 됩니다. rb는 첫 숫자가 1인 정수가 되므로 첫 숫자인 1을 삭제한 문자열로 정의합니다. {{{#!if rp>ap {{{#!if ru=ru+1, rb=rb.substr(1, rp-1) }}}}}} rb가 소수점 아래 자릿수를 초과하지 않을 경우 rb를 다시 정의할 필요 없이 그대로 둡니다. {{{#!if rp<=ap }}} {{{#!if ps=true }}} }}} Case 1-2 : rb가 음수인 경우 ru에서 1을 빌려옵니다. 1보다 작은 양수값에서 1보다 작은 양수값을 빼면 -1보다 작을 수 없으며, 소수점 아래 자릿수가 초과되지 않습니다. {{{#!if (+rb<0)&&!ps {{{#!if ru=ru-1 }}} 소수점 아래 자릿수인 ap만큼 10을 제곱한 값(tv)을 rb에서 증가시켜 rb를 재정의합니다. 그러면 rb는 양수가 됩니다. 그리고 rb를 다시 문자열로 변환합니다. {{{#!if rb=tv+(+rb) }}}{{{#!if rb=rb.toString() }}} {{{#!if ps=true }}}}}} 정리과정을 끝냈으면 ru를 string으로 변환합니다. {{{#!if this.ru=ru.toString() }}}}}} Case 2 : ru가 0인 경우 ru가 0이 되면 rb의 값이 양수인지 음수인지에 따라 달라집니다. {{{#!if ru==0 Case 2-1 : rb가 0 이상인 경우 {{{#!if (+rb>=0)&&!ps rb가 양수이면서 rb가 자릿수를 초과한 경우 rb는 첫 숫자가 1인 정수가 되므로 첫 숫자인 1을 삭제한 문자열로 정의합니다. {{{#!if rp>ap {{{#!if ru=ru+1, rb=rb.substr(1, rp-1) }}}}}}{{{#!if ps=true }}}}}} Case 2-2 : rb가 음수인 경우 {{{#!if (+rb<0)&&!ps rb가 음수이면서 rb가 자릿수를 초과한 경우 값이 0인 ru에 1을 빼야 합니다. 그리고 rb가 "-"+숫자 꼴이므로 문자열의 1번 index에 해당하는 1을 지워야 합니다. 앞에서 rb가 음수인 경우 rp는 rb의 마이너스(-)가 차지하는 자릿수를 계산하지 않은 값 곧 숫자들이 차지하는 자릿수이므로, rb를 길이가 rp-1인 숫자들로 다시 정의합니다. {{{#!if rp>ap {{{#!if ru=ru-1, rb=rb.substr(2, rp-1) }}}}}} rb가 자릿수를 초과하지 않은 경우 rb에서 "-"를 뺀 문자열로 rb를 다시 정의합니다. {{{#!if rp<=ap {{{#!if rb=rb.substr(1, rp) }}}}}}{{{#!if ps=true }}}}}} 정리과정을 끝냈으면 ru를 string으로 변환합니다. {{{#!if this.ru=ru.toString() }}} -0.xxxx 같이 (ru==0인데) 연산결과가 -1보다 큰 음수로 나오는 경우 ru 문자열 앞에 "-"를 붙입니다. f가 "+"인지 "-"인지에 따라 처음 rb를 정의할 때 적었던 식을 다시 불러옵니다. {{{#!if ((f=="+")&&((+ab)+(+bb)<0))||((f=="-")&&((+ab)-(+bb)<0)) {{{#!if ru="-"+ru }}}}}} }}} Case 3 : ru가 0보다 작은 경우. 곧 -1 이하인 음수가 되는 경우. {{{#!if ru<0 Case 3-1 : rb가 0 이하인 경우 {{{#!if (+rb<=0)&&!ps rb가 음수이면서 자릿수를 초과한 경우 ru에 -1을 빼고, rb의 음수기호(-)와 첫번째 숫자인 문자열 "1"을 뺀 문자열로 rb를 다시 정의합니다. {{{#!if rp>ap {{{#!if rb=rb.substr(2, rp-1) }}} }}} rb가 자릿수를 초과하지 않은 경우 rp는 음수기호를 제외한 숫자 자릿수이므로 rb를 음수기호만을 뺀 문자열로 다시 정의합니다. 단, rb가 0이 되면 rp==1이 되므로 rb==0인 경우는 제외합니다. {{{#!if (rp<=ap)&&(+rb<0) {{{#!if rb=rb.substr(1, rp) }}}}}}{{{#!if ps=true }}}}}} Case 3-2 : rb가 0보다 큰 경우. 소수점 아래 부분을 보면 -1보다 큰 음수값에서 -1보다 큰 음수값을 빼면 1보다 클 수 없으며, 소수점 아래 자릿수가 초과되지 않습니다. {{{#!if (+rb>0)&&!ps ru<=-1이므로 ru+1를 해도 최대 0이 됩니다. {{{#!if ru=ru+1 }}} rb>0에서 rb은 음수(계산결과)의 음수(마이너스값이 줄어듦)이므로 rb의 자릿수인 rp만큼 10을 제곱한 값(tv)에서 rb을 '''뺀''' 값으로 rb를 재정의합니다. 그러면 rb는 양수이지만 계산결과인 음수에 맞춘 값이 됩니다. 그리고 rb를 다시 문자열로 변환합니다. 변환합니다. {{{#!if rb=tv-(+rb) }}}{{{#!if rb=rb.toString() }}}{{{#!if ps=true }}}}}} 정리과정을 끝냈으면 ru를 string으로 변환합니다. {{{#!if this.ru=ru.toString() }}} -0.xxxx 같이 (ru==0인데) 연산결과가 -1보다 큰 음수로 나오는 경우가 된다면 ru 문자열 앞에 "-"를 붙입니다. {{{#!if +ru==0 {{{#!if ru="-"+ru }}}}}} }}} 여기까지가 소수점 아래 자릿수 숫자들의 계산과정입니다. }}} a와 b 모두 정수인 경우 ap, bp는 모두 0이 되므로 ru만을 그대로 문자열로 바꾸면 되며 소수점 아래(rb)는 표기해야 할 필요가 없으므로 rb="", (소수점 아래 자릿수)rp=0을 반환합니다. {{{#!if (ap==0)&&(bp==0) {{{#!if this.ru=ru.toString(), rb="", rp=0+0 }}}}}} rb==0인 경우 rb="", rp=0을 반환합니다. {{{#!if +rb==0 {{{#!if rb="", rp=0+0 }}}}}} 이제 rb=""이 아닌 경우 소수점 아래 숫자 정리를 합니다. rp를 rb의 문자열 길이로 다시 정의합니다. {{{#!if rb!="" {{{#!if this.rp=rb.length }}} +"000100"을 숫자로 바꾸면 100이 되는 문제가 있습니다. 이처럼 소수점 아래 자릿수를 연산한 결과를 문자열로 바꿨을 때 기존 소수점 아래 자릿수보다 작은 길이가 나오면 앞쪽에 0을 보충합니다. 앞에서 ap,bp를 똑같이 맞췄으므로 ap를 가져옵니다. 자릿수가 모자랄 경우 0을 하나씩 보충합니다. {{{#!if rp<ap {{{#!if rb=pd.substr(0,ap-rp)+rb }}}}}} 앞에 0을 채웠다면 이제, 소수점 아래로 나오는 숫자를 보고 마지막에서부터 0이 나오면 한 자리씩 지우는 과정을 시작합니다. 여기까지가 덧셈 또는 뺄셈연산의 계산과정이며 과정은 이후 rb 정리 과정으로 넘어갑니다. }}}}}} ##== 곱셈 & 나눗셈 == ##=== 숫자 초기화 === {{{#!if (f=="*")||(f=="/") 곱셈 및 나눗셈 연산과정을 봅니다. 18자리 숫자로 입력할 수 있는 최대 정수는 999,999,999,999,999,999입니다. 다행히 999,999,999,999,999,999*9=8,999,999,999,999,999,991 < long 한계치 9,223,372,036,854,775,807 이라서 a*각 자릿수로 덧셈해볼 수는 있습니다. 음수가 될 경우 소수점 윗부분 문자열은 "-" 기호가 붙으므로, 이것을 이용한 조건문을 하나 만들어 a와 b 둘의 부호가 서로 다를 경우 (a만 음수이거나 b가 음수일 경우) 계산 결과에 부호를 표시할 수 있게 만듭니다. {{{#!if (au[0]==45)^(bu[0]==45) {{{#!if ns="-" }}}}}} a 또는 b가 음수가 될 경우 소수점 윗부분 문자열인 au 또는 bu에서 마이너스(-)를 제거합니다. {{{#!if au[0]==45 {{{#!if au=au.substr(1,ad-1) }}}}}} {{{#!if bu[0]==45 {{{#!if bu=bu.substr(1,bd-1) }}}}}} 그 다음 --앞자리에 0만 여러 개 적어놓고 장난치는 사람이 있을까봐-- au를 값으로 바꾼 다음 다시 문자열로 변환하여 앞자리에 있는 0들을 모두 삭제합니다. bu도 그렇게 둡니다. {{{#!if au=+au, au=au.toString(), bu=+bu, bu=bu.toString() }}} ##=== 자릿수 측정 === 나누는 자릿수에 맞춰 결과를 표시하고자 ac, bc를 자릿수를 나타내는 값으로 정의합니다. 먼저 au는 앞에 적어놓은 0을 제거한 문자열이므로 +au>0인 경우 ac를 au의 문자열 길이에서 1을 뺀 값으로 정의합니다. {{{#!if +au>0 {{{#!if ac=au.length-1 }}}}}} (au, ab 둘다 0인 경우 앞에 처리하는 식이 있으며) au가 0이라면 ab는 0보다 크며, 소수점 아래 처음으로 0이 아닌 수가 나오는 자릿수를 고른 다음 덧셈 연산에서 그 수의 역원이 되는 수를 ac로 정의합니다. 이를 구하고자 뒤에 0을 더 붙여 18자리 숫자로 만든 다음 정수로 바꾸어 구합니다. {{{#!if +au==0 {{{#!if ac=ab+pd, ac=ac.substr(0,18), ac=+ac, ac=ac.toString(), ac=ac.length-19 }}}}}} bc도 a와 같은 방법으로 정의합니다. {{{#!if +bu>0 {{{#!if bc=bu.length-1 }}}}}}{{{#!if +bu==0 {{{#!if bc=bb+pd, bc=bc.substr(0,18), bc=+bc, bc=bc.toString(), bc=bc.length-19 }}}}}} ##=== 0인자 처리 === a 또는 b값이 0이 되려면 au, ab 둘 다 0이 되거나 bu, bb 둘 다 0이 되어야 합니다. a 또는 b 값이 0일 경우 당연히 음수 부호가 표시되지 않습니다. {{{#!if ((+au==0)&&(+ab==0))||((+bu==0)&&(+bb==0)) 곱셈에서 0을 곱하면 0이 되므로, 곱셈의 경우 a 또는 b가 0이 될 때 계산 결과에 0을 반환합니다. {{{#!if f=="*" {{{#!if rs="", ru="0", rb="", ri="", rp=0, ns="" }}}}}} 나눗셈에서 나누는 수(b)가 0이 될 경우 오류를 반환하고 ps=true를 걸어 나눗셈 연산이 되지 않게 만듭니다. {{{#!if f=="/" {{{#!if ((+bu==0)&&(+bb==0)) error code 03 번 : 0으로 나눌 수 없습니다. {{{#!if eb=03, ps=true }}}}}} 나누는 수가 0이 아니면서 나눌 대상이 0이 될 경우 곱셈에서 0을 곱하는 것처럼 계산 결과에 0을 반환합니다. {{{#!if ((+au==0)&&(+ab==0))&&((+bu!=0)||(+bb!=0)) {{{#!if rs="", ru="0", rb="", ri="", rp=0, ns="" }}}}}} }}}}}} 곱셈과 나눗셈에서 a와 b 모두 0이 아닌 경우를 봅니다. {{{#!if ((+au!=0)||(+ab!=0))&&((+bu!=0)||(+bb!=0)) ##=== 곱셈 === {{{#!if f=="*" 곱셈계산에서 18자리씩 곱셈을 할 수 있도록 입력했던 a와 b의 문자열을 확장할 것입니다. a와 b 각각 소수점 윗자리와 소수점 아래자리의 문자열의 빈 공간을 0으로 채워 18자로 만듭니다. 소수점 윗자리는 왼쪽에서 0을 채워나갑니다. {{{#!if au = pd + au +18자}}}{{{#!if au=au.substr(au.length-18,18) }}} {{{#!if bu = pd + bu +18자}}}{{{#!if bu=bu.substr(bu.length-18,18) }}} 소수점 아래자리는 오른쪽에서 0을 채웁니다. (ap, bp값은 보존됩니다.) {{{#!if ab += pd +18자}}}{{{#!if ab=ab.substr(0,18) }}} {{{#!if bb += pd +18자}}}{{{#!if bb=bb.substr(0,18) }}}}}} {{{#!if f=="/" 나눗셈은 소수점 위 18번째 자리부터 내려가면서 처음으로 0이 아닌 숫자가 있으면 그 숫자가 처음 숫자가 되도록 숫자를 왼쪽으로 밀어두려고 합니다. 그 다음 오른쪽을 0으로 채웁니다. au를 왼쪽으로 밀 경우 남게 되는 자릿수를 변수 tu로 둡니다. (후술할 아래 곱셈연산과 겹치지 않습니다.) {{{#!if tu=18-au.length, au=au+ab.substr(0,tu)+pd, ab=ab.substr(tu)+pd, au=au.substr(0,18), ab=ab.substr(0,18) }}} {{{#!if tu=18-bu.length, bu=bu+bb.substr(0,tu)+pd, bb=bb.substr(tu)+pd, bu=bu.substr(0,18), bb=bb.substr(0,18) }}} }}} }}} 여기까지 곱셈 또는 나눗셈에서 숫자를 초기화하는 과정입니다. }}} a와 b 모두 0이 아닌 경우에서 곱셈을 연산하는 과정입니다. {{{#!if (f=="*")&&((+au!=0)||(+ab!=0))&&((+bu!=0)||(+bb!=0)) 곱셈은 18자리를 끊어서 계산합니다. 소수점 아래 18자리의 아래인 제19~36번 자리를 ri로 둡니다. 소수점 위 19~36번째 자리는 rs로 두어 ri, rb, ru, rs 순으로 계산합니다. 소수점 위 18자리, 소수점 아래 18자리인 두 수를 곱하면 해당하는 자리별로 곱셈을 할 때 최대 (18+18)**2=1296회를 곱해야 합니다. 앞으로 있을 계산은 다음과 같습니다. * ri를 더했더니 ri가 19자리 숫자로 넘치면 넘친 앞의 1자리를 rb로 넘깁니다. * rb가 19자리로 넘쳤다면 넘친 앞의 1자리를 ru로 넘깁니다. * ru가 19자리로 넘친다면 넘친 앞의 1자리를 rs로 넘깁니다. (rs는 상용로그로 보았을 때 log a<18, log b<18 에서 log (a*b) = log a + log b < 36이므로 19자리로 넘치지 않습니다.) 문자열로 바꾸고 문자열을 쪼갠 다음 숫자로 바꾸는 과정입니다. 이를 if로 바꾸면 다음과 같습니다. {{{#!if false {{{#!if ri=ri.toString(), ri.length==19 {{{#!if rb=(+rb)+(+ri.substr(0,1)), ri=(+ri.substr(1,18)) }}}}}} {{{#!if rb=rb.toString(), rb.length==19 {{{#!if ru=(+ru)+(+rb.substr(0,1)), rb=(+rb.substr(1,18)) }}}}}} {{{#!if ru=ru.toString(), ru.length==19 {{{#!if rs=(+rs)+(+ru.substr(0,1)), ru=(+ru.substr(1,18)) }}}}}} }}} 변수 tv, tw, i, ps를 가져옵니다. tw는 0, tv는 1, i는 0, ps는 false으로 초기화 된 채로 있습니다. 연산 과정 중간중간에 마지막 자릿수를 보정하고자 10씩 곱하게 됩니다. ri에서 최대 18자리에서 1자리 수를 곱하면 19자리가 될 수 있으므로 곱셈할 때마다 19자리로 넘칠때마다 넘치는 숫자는 rb로 넘깁니다. ri부분을 합산합니다. ab*bb 의 절반을 처리합니다. (자릿수끼리 대입했을 때 처리되는 부분이 먼저 입력한 절반이 나중에 입력하는 절반보다 더 많지만, 편의상 절반이라고 적습니다.) ## for i=0 to 17 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=1 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=2 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=3 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=4 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=5 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=6 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=7 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=8 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=9 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=10 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=11 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=12 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=13 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=14 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=15 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=16 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=17 {{{#!if tw=(+ab.substr(i,18-i))*(+bb.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rb=rb+(+tw.substr(0,1)), ri=ri+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ri=ri+(+tw) }}}}}}{{{#!if ps=false, ri=ri.toString(), ri.length==19 {{{#!if rb=rb+(+ri.substr(0,1)), ri=(+ri.substr(1,18)), ps=true }}}}}}{{{#!if (ri.length<=18)&&!ps {{{#!if ri=(+ri) }}}}}} ##rb rb부분을 합산합니다. substr(-1,0)은 빈 문자열 값이 나옵니다. (ab*bb의 나머지 절반 + au*bb의 절반), ab*bu의 절반을 처리합니다. i, tv, ps를 다시 초기화하고 시작합니다. {{{#!if i=0+0, tv=1, ps=false }}} ##for i=0 to 17 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=1 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=2 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=3 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=4 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=5 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=6 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=7 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=8 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=9 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=10 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=11 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=12 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=13 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=14 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=15 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=16 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=17 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bb.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}} {{{#!if ps=false, tw=(+ab.substr(i,18-i))*(+bu.substr(17-i,1))*tv }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if ru=ru+(+tw.substr(0,1)), rb=rb+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if rb=rb+(+tw) }}}}}}{{{#!if ps=false, rb=rb.toString(), rb.length==19 {{{#!if ru=ru+(+rb.substr(0,1)), rb=(+rb.substr(1,18)), ps=true }}}}}}{{{#!if (rb.length<=18)&&!ps {{{#!if rb=(+rb) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ##ru ru부분을 합산합니다. substr(-1,0)은 빈 문자열 값이 나옵니다. (ab*bu의 나머지 절반 + au*bu의 절반), au*bb의 나머지 절반을 처리합니다. i, tv, ps를 다시 초기화하고 시작합니다. {{{#!if i=0+0, tv=1, ps=false }}} ##for i=0 to 17 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=1 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=2 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=3 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=4 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=5 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=6 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=7 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=8 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=9 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=10 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=11 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=12 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=13 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=14 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=15 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=16 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ## i=17 {{{#!if ps=false, tw=+(au.substr(i,18-i)+ab.substr(0,i)), tw=tw*(+bu.substr(17-i,1)) }}}{{{#!if tw=tw.toString(), tw.length==19 {{{#!if rs=rs+(+tw.substr(0,1)), ru=ru+(+tw.substr(1,18)), ps=true }}}}}}{{{#!if (tw.length<=18)&&!ps {{{#!if ru=ru+(+tw) }}}}}}{{{#!if ps=false, ru=ru.toString(), ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}} {{{#!if ps=false, tw=(+au.substr(0,i))*(+bb.substr(17-i,1)), ru=ru+(+tw), ru=ru.toString() }}}{{{#!if ru.length==19 {{{#!if rs=rs+(+ru.substr(0,1)), ru=(+ru.substr(1,18)), ps=true }}}}}}{{{#!if (ru.length<=18)&&!ps {{{#!if ru=(+ru) }}}}}}{{{#!if i+=1, tv*=10, ps=false }}} ##rs rs부분을 합산합니다. au*bu의 나머지 절반을 처리합니다. i, tv, ps를 다시 초기화하고 시작합니다. 소수점 윗자리는 많아야 36자리이므로 rs에서 더 이상 넘치지 않습니다. {{{#!if i=0+0, tv=1, ps=false }}} ##for i=0 to 17 {{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}} {{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}}{{{#!if tw=(+au.substr(0,i))*(+bu.substr(17-i,1)), rs=rs+tw, i+=1 }}} 여기까지가 곱셈에서 a*b 의 연산 과정이며 rb 정리 부분으로 넘어갑니다. }}} ##=== 나눗셈 === a와 b 모두 0이 아닌 경우에서 나눗셈을 연산하는 과정입니다. {{{#!if (f=="/")&&((+au!=0)||(+ab!=0))&&((+bu!=0)||(+bb!=0)) au, ab, bu, bb를 18자로 만들었으므로 36자리 정수의 나눗셈으로 봅니다. a/b=(au+ab)/(bu+bb)=(+(au.substr(0,18)+ab.substr(0,18)))/(+(bu.substr(0,18)+bb.substr(0,18)))와 같습니다. ##몫 서술 제일 높은 자리부터 내려오면서 처음으로 0이 아닌 수를 왼쪽으로 당기는 과정을 거쳤으므로 (1부터 시작하는 18자리+18자리 숫자)/(1부터 시작하는 18자리+18자리 수) 연산이 됩니다. {{{#!if ps=false }}}숫자에서 해당하는 (10**n) 자리에 몫을 더 이상 계산하지 않고 그 다음 자리(10**(n+1))의 몫을 계산하게 된다면 ps를 true로 바꿉니다. ##i=0 {{{#!if br=false }}}다시 정렬된 bu, bb의 값은 바뀌지 않습니다. bu, bb로 나눈 몫만큼 au, ab에서 감소시킨 다음 au와 ab를 다시 정렬시키며, au와 ab가 모두 0이 되면 더 이상 계산하지 않도록 br를 true로 반환합니다. au와 ab의 값을 가져와 tu와 tv로 먼저 복제합니다. (계산 결과에 쓰게 됩니다.) {{{#!if tu=au, tv=ab }}} 그 다음 계산을 편하게 할 수 있도록 텍스트값으로 된 au, ab, bu, bb를 정수값으로 변환합니다. {{{#!if au=+au, ab=+bb, bu=+bu, bb=+bb }}} au의 값이 bu보다 작거나, au==bu이더라도 ab<bb이면 해당하는 자릿수의 몫이 0이라는 의미리므로 다음 자릿수로 넘깁니다. 이 과정에서 변수 ps(logical)를 false로 초기화한 다음 가져옵니다. {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true }}}}}} !ts이러면 ① au>bu이거나, ② au==bu이고 ab>=bb인 경우입니다. !ts이고 !ps(다음 자릿수로 계산을 넘기지 않음)임을 if 조건문으로 둔 상태에서 진행합니다. {{{#!if !ps au를 bu로 나눈 몫을 tw로 정의합니다. 정수를 정수로 나누면 몫만 계산되며, 100,000,000,000,000,000 이상 999,999,999 999,999,999 이하의 한 정수를 100,000,000,000,000,000 이상의 다른 한 정수로 나눈 몫이므로 tw의 값은 최소 0 최대 9가 됩니다. {{{#!if tw=au/bu }}} bu, bb를 각각 tw만큼 곱한 값을 tx, ty로 정의합니다. {{{#!if tx=bu*tw, ty=bb*tw }}} 이 때 ty가 19자리가 되면 넘친 첫번째 자리의 값을 tx의 일의 자리로 더하고 아래 18자리의 값을 ty로 다시 정의합니다. tx는 19자리 숫자가 되어도 문제가 없습니다. {{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} 이렇게 하면 tx=bu*tw<=au가 됩니다. (bu가 au보다 크면 tw는 tw의 정의에서 값이 0이 되므로 부등호가 성립됩니다.) ty를 정수로 바꿉니다. {{{#!if ty=+ty }}} (2.1/1.6 처럼) ty가 넘쳐 tx 값이 더해지는 경우가 있으므로 몫이 유효한 값인지 검산합니다. 만일 tx ty 가 기존 au ab을 넘게 되면 tw에서 1을 빼고, tx, ty를 다시 정의합니다. {{{#!if (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}} 마찬가지로 ty가 19자리가 된다면 넘친 첫번째 자리의 값을 tx의 일의 자리로 더합니다. {{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} ty를 정수로 바꿉니다. {{{#!if ty=+ty }}} }}} 이렇게 만들어진 tx, ty가 있으면 이를 반영합니다. }}} ps일 경우 해당 자리의 몫(tw)을 0으로 처리합니다. {{{#!if ps {{{#!if tw=0 }}}}}} !ps일 경우 au에서 tx를, ab에서 ty를 뺍니다. 만약 ty>ab일 경우 au에서 1을 가져와 (au에서 1을 빼고) ab에 1,000,000,000,000,000,000을 더한 다음 계산합니다. {{{#!if !ps {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}} {{{#!if au-=tx, ab-=ty }}}}}} 몫인 tw를 문자열로 바꾸고 tm의 오른쪽에 더합니다. {{{#!if tw=tw.toString(), tm+=tw }}} au, ab에서 몫을 빼고 나니 au, ab가 모두 0으로 된다면 더 이상 계산을 하지 않아야 하므로 br를 true로 반환합니다. {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}} 어느 하나가 0이 되지 않는다면 br는 여전히 false이므로 !br일 때 자릿수를 옮깁니다. {{{#!if !br au, ab를 문자열로 다시 바꿉니다. {{{#!if au=au.toString(), ab=ab.toString() }}} tn을 빈 문자열로 초기화합니다. 그리고 역할을 다 한 ps를 false로 초기화합니다. 그 다음 au가 여전히 18자리 숫자일 경우 au의 첫번째 자리를 분리해 내어 tn으로 정의합니다. 여기서 ps는 au의 길이에 따른 처리가 겹쳐지지 않게 만듭니다. {{{#!if ps=false, tn="", au.length==18 {{{#!if tn=au.substr(0,1), au=au.substr(1,17), ps=true }}}}}} au가 17자리 미만의 숫자가 되었다면 au의 왼쪽을 0으로 채워 18자리 숫자로 만듭니다. {{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}} ab가 18자리 미만의 숫자가 되었다면 왼쪽을 0으로 채워 18자리 숫자로 만듭니다. {{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}} au의 뒤로 ab의 처음 자리를 끌어옵니다. {{{#!if au+=ab.substr(0,1) }}} ab의 나머지 17자리를 앞으로 당긴 다음 "0"을 더합니다. {{{#!if ab=ab.substr(1,17)+"0" }}} 여기까지가 자릿수를 한 칸씩 옮기는 과정입니다. }}} ##i=1 part 1 몫으로 기록할 숫자의 첫번째 자리를 구했다면, 그 다음 자리의 숫자를 찾기 위해 (변수 tn으로 만들 수 있는 여분의 1자리 +) 18자리 + 18자리 숫자를 18자리+18자리 숫자로 나누는 계산을 합니다. tn이 9가 될 경우 9로 시작하는 19자리 숫자를 long integer로 모두 표현할 수 없으므로 10**18 자리부터 먼저 계산합니다. 10**18의 1번째 숫자의 몫을 구한 다음 나머지를 18자리 숫자에 더하는 과정(part 1)을 거친 다음 그 18자리에서 몫을 구하는 과정(part 2)을 거칩니다. au와 ab를 정수로 다시 바꾸고 tz를 0으로 초기화합니다. 그리고 tn이 빈 문자열이 아니라면 (앞에 au에서 한 자리 수를 떼온 것이므로) tn에 0을 더하여 19자리로 만들고 몫을 구합니다. {{{#!if au=+au, ab=+ab, tz=0, tn!="" tn을 19자리 정수로 바꿉니다. {{{#!if tn+=pd, tn=+tn, }}} tz를 몫으로 정의합니다. 앞의 tw를 처리하는 방법과 같습니다. tn을 정수로 만들었으므로 소수점 아래를 비교한다면 정수의 소수점 아래에 해당하는 0과 비교합니다. {{{#!if tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty }}} {{{#!if (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty }}}}}} tn에서 나누어떨어지는 값을 뺀 나머지를 반영하여 au, ab에 더합니다. 소수점 아래 부분인 ab보다 ty가 크다면 tn에서 1을 빼어 계산합니다. {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}} {{{#!if au+=(tn-tx), ab-=ty }}} tn을 빈 문자열로 초기화합니다. {{{#!if tn="" }}} }}} ##i=1 part 2 br(0으로 나누어떨어짐) 이 걸려있으면 실행하지 않습니다. 그러므로 전체적으로 조건을 !br로 둔 다음 계산을 진행합니다. {{{#!if !br ps를 false로 초기화한 다음 앞에서 했던 처리와 동일하게 진행합니다. {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) ts일 경우 ps를 true로 바꾸며, "ps일 경우 tw를 0으로 처리하는 과정을 여기로 병합합니다. {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps tw, tx, ty를 정의하고 처리하는 과정은 앞자리에서 몫을 찾는 과정과 동일합니다. 앞에서 이미 au, ab를 정수로 만들었으므로 여기에 au, ab를 정수로 만드는 처리를 할 필요가 없습니다. {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} ty를 정수로 바꾸는 과정을 아래 if 조건문으로 병합합니다. {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} 앞에서 계산된 tz의 값을 tw에 더한 다음 tw를 문자열로 바꿉니다. 그리고 tm에 문자열로 바꾼 tw을 더합니다. {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} ts를 au와 ab가 모두 0이 되는 조건으로 다시 정의합니다. {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} 어느 자릿수부터 br가 true로 되면 이후 자릿수 옮겨 몫을 구하는 과정이나 나머지를 정리하는 과정을 더 이상 할 필요가 없습니다. {{{#!if !br au, ab를 문자열로 다시 바꾸고 처리하는 과정은 동일합니다. {{{#!if au=au.toString(), ab=ab.toString() }}} ps를 au 자릿수가 18이 되었을 때 true가 되는 논리값으로 정의합니다. {{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}} {{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}} {{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}} {{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}} }}} ##i=2 이후부터 과정은 동일합니다. 많아야 소수점 위 36자리, 소수점 아래 36자리 모두를 쓰면 72개이므로 총 72회(for i=0 to i=71)를 진행합니다. {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=3 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=4 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=5 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=6 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=7 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=8 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=9 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=10 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=11 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=12 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=13 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=14 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=15 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=16 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=17 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=18 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=19 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=20 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=21 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=22 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=23 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=24 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=25 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=26 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=27 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=28 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=29 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=30 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=31 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=32 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=33 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=34 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=35 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=36 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=37 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=38 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=39 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=40 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=41 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=42 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=43 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=44 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=45 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=46 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=47 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=48 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=49 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=50 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=51 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=52 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=53 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=54 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=55 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=56 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=57 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=58 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=59 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=60 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=61 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=62 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=63 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=64 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=65 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=66 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=67 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=68 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=69 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=70 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} {{{#!if !br {{{#!if au=au.toString(), ab=ab.toString() }}}{{{#!if tn="", ps=(au.length==18), ps {{{#!if tn=au.substr(0,1), au=au.substr(1,17) }}}}}}{{{#!if !ps&&(au.length<17) {{{#!if au=pd+au, au=au.substr(au.length-17,17) }}}}}}{{{#!if ab.length<18 {{{#!if ab=pd+ab, ab=ab.substr(ab.length-18,18) }}}}}}{{{#!if au+=ab.substr(0,1), ab=ab.substr(1,17)+"0" }}}}}} ##i=71 {{{#!if au=+au, ab=+ab, tz=0, !br&&(tn!="") {{{#!if tn+=pd, tn=+tn, tz=tn/bu, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>tn)||((tx==tn)&&(ty>0)) {{{#!if tz-=1, tx=bu*tz, ty=bb*tz }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if tn-=1, ab+=+("1"+pd) }}}}}}{{{#!if au+=(tn-tx), ab-=ty, tn="" }}}}}} {{{#!if !br {{{#!if ps=false, (au<bu)||((au==bu)&&(ab<bb)) {{{#!if ps=true, tw=0 }}}}}} {{{#!if !ps {{{#!if tw=au/bu, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}} {{{#!if ty=+ty, (tx>au)||((tx==au)&&(ty>ab)) {{{#!if tw-=1, tx=bu*tw, ty=bb*tw }}}{{{#!if ty=ty.toString(), ty.length==19 {{{#!if tx+=+(ty.substr(0,1)), ty=ty.substr(1,18) }}}}}}{{{#!if ty=+ty }}}}}} {{{#!if ty>ab {{{#!if au-=1, ab+=+("1"+pd) }}}}}}{{{#!if au-=tx, ab-=ty }}}}}} {{{#!if tw+=tz, tw=tw.toString(), tm+=tw }}} {{{#!if (au==0)&&(ab==0) {{{#!if br=true }}}}}}}}} tn을 빈 문자열로, ts를 false로 초기화합니다. 마지막 72회까지 몫을 구하는 계산을 했음에도 불구하고 나머지가 나누어떨어져 0이 되지 않는다면 tn을 "..."로, ts를 true로 바꿉니다. {{{#!if tn="", ts=false, !br {{{#!if tn="...", ts=true }}}}}} ##rs 매기기 앞에 매겼던 ac와 bc로 판별식을 만듭니다. i=ac-bc로 둡니다. a의 가장 큰 자리와 b의 가장 큰 자리가 얼마나 차이나는가에 따라 몫에 매기는 소수점 위치가 달라집니다. i>=-35 (ac==-18이고 bc==17일 경우), i<=35 (ac==17이고 bc=-18일 경우)입니다. i가 18 이상 (18 이상 35 이하)이면 rs를 매길 수 있습니다. 몫을 적어놓은 문자열 tm의 0번 index에 들어가는 문자부터 i에서 18을 뺀 값의 index에 들어가는 문자까지를 rs로 두며, rs의 문자열 길이는 i-18+1 곧 i-17입니다. {{{#!if i=ac-bc, i>=18 tm에서 rs를 오려낸 문자열을 tm으로 다시 둡니다. {{{#!if rs=tm.substr(0,i-17), tm=tm.substr(i-17) }}}}}} ##ru 매기기 i>=18 이 되(어 rs를 매기)는 경우 i를 17로 맞춥니다. {{{#!if i>=18 {{{#!if i=17 }}}}}} i가 0 이상 (0 이상 17 이하)이면 ru를 매길 수 있으며 문자열의 길이는 i+1이 됩니다. {{{#!if i>=0 {{{#!if ru=tm.substr(0,i+1), tm=tm.substr(i+1) }}}}}} ##rb 매기기 i>=0이 되(어 ru를 매기)는 경우 i를 -1로 맞춥니다. {{{#!if i>=0 {{{#!if i=-1 }}}}}} i가 -18 이상 (-18 이상 -1 이하)이면 rb를 매길 수 있으며 문자열의 길이는 i+18+1 곧 i+19가 됩니다. {{{#!if i>=-18 {{{#!if rb=tm.substr(0,i+19), tm=tm.substr(i+19), rb=rb+pd, rb=rb.substr(0,18) }}}}}} ##ri 매기기 i>=-18이 되(어 rb를 매기)는 경우 i를 -19로 맞춥니다. {{{#!if i>=-18 {{{#!if i=-19 }}}}}} i가 -19 이하 (-36이상 -19 이하이나, i의 최소값은 -35)이면 ri를 매길 수 있습니다. {{{#!if i>=-36 {{{#if false {{{#!if ri=tm.substr(0,i+37), tm=tm.substr(i+37), ri=ri+pd, ri=ri.substr(0,18) }}}}}} {{{#!if ri=tm.substr(0,18), tm=tm.substr(18), ri=ri+pd, ri=ri.substr(0,18) }}}}}} 여기까지가 나눗셈의 계산과정입니다. }}} ##== 계산 결과 표시 정리하기 == 연산이 끝났으면 표기된 숫자를 정리합니다. ##ru 정리 부분 먼저 (곱셈연산에서 정수값으로 나오는) ru를 문자열로 변환합니다. {{{#!if ru=ru.toString() }}} 18자리씩 끊어 표기하므로 소수점 위 19~36번째 자리에 해당하는 rs값이 (가령 곱셈에서, 곱한 값을 더한 결과가) 0일 경우 rs를 빈 문자열로 바꿉니다. 이 때 ru를 정수로 바꿔 ru 왼쪽에 있는 0들을 지운 다음, ru를 문자열로 바꿉니다. {{{#!if +rs==0 {{{#!if rs="", ru=+ru, ru=ru.toString() }}}}}} 계산과정에서 ru의 윗자리인 rs값이 0보다 클 경우, 1~18번째 자리인 ru에 빈 자리를 채우도록 ru의 왼쪽을 0으로 채웁니다. {{{#!if +rs>0 {{{#!if rs=rs.toString(), ru=pd+ru, ru=ru.substr(ru.length-18, 18) }}} rs를 정수로 바꿔 rs 앞에 있는 0들을 지운 다음 rs를 문자열로 바꿉니다. {{{#!if rs=+rs, rs=rs.toString() }}}}}} ##rb 정리 부분 소수점 아래 마지막 문자의 번호는 (.length - 1)입니다. 극단적으로 .10000 00000 00000 000 같은 것이 나올 수 있겠지만 18회 조사합니다. substr(0,0)으로 하면 ""이 됩니다. 곱셈연산이면서 ri가 빈 문자열이 아닐 경우 true를 주는 논리값으로 ps를 정의합니다. {{{#!if ps=((f=="*")&&(ri>0)) }}} 소수점 아래 19~36번째 자리에 해당하는 ri값이 0일 경우 ri를 빈 문자열로 바꿉니다. 이 때 ri와 rb가 모두 0일 경우 rb도 빈 문자열로 바꾸고 rp=0으로 둡니다. {{{#!if ri==0 {{{#!if ri="" }}}{{{#!if rb==0 {{{#!if rb="", rp=0 }}}}}}}}} 곱셈 과정에서 ri가 0보다 클 경우 rb를 문자열로 변환하고 rb, ri의 왼쪽을 0으로 채웁니다. {{{#!if ps {{{#!if rb=rb.toString(), ri=ri.toString(), rb=pd+rb, rb=rb.substr(rb.length-18, 18), ri=pd+ri, ri=ri.substr(ri.length-18, 18) }}}}}} ri가 비었고 rb가 0이 아닌 경우 rb를 문자열로 바꾼 다음 왼쪽을 0으로 채웁니다. {{{#!if !ps&&(rb>0) {{{#!if rb=rb.toString(), rb=pd+rb, rb=rb.substr(rb.length-18, 18) }}}}}} ps가 true이면 rp를 ri의 길이로, 그렇지 않고 rb만 0이 아닌경우 rp를 rb의 길이로 정의합니다. {{{#!if ps {{{#!if this.rp=ri.length }}}}}}{{{#!if !ps&&(rb!="") {{{#!if this.rp=rb.length }}}}}} 곱셈연산이면서 ri가 빈 문자열이 아닐 경우 ri의 오른쪽부터 붙은 "0"들을 모두 지웁니다, 그렇지 않을 경우 rb의 오른쪽에 붙은 "0"들을 모두 지웁니다, {{{#!if ps {{{#!if (rp>9)&&(ri.substr(rp-9,9)=="000000000") {{{#!if this.ri=ri.substr(0,rp-9), rp=rp-9 }}}}}} {{{#!if (rp>4)&&(ri.substr(rp-4,4)=="0000") {{{#!if this.ri=ri.substr(0,rp-4), rp=rp-4 }}}}}} {{{#!if (rp>2)&&(ri.substr(rp-2,2)=="00") {{{#!if this.ri=ri.substr(0,rp-2), rp=rp-2 }}}}}} {{{#!if (rp>2)&&(ri.substr(rp-2,2)=="00") {{{#!if this.ri=ri.substr(0,rp-2), rp=rp-2 }}}}}} {{{#!if (rp>1)&&(ri.substr(rp-1,1)=="0") {{{#!if this.ri=ri.substr(0,rp-1), rp=rp-1 }}}}}}}}} {{{#!if !ps {{{#!if (rp>9)&&(rb.substr(rp-9,9)=="000000000") {{{#!if this.rb=rb.substr(0,rp-9), rp=rp-9 }}}}}} {{{#!if (rp>4)&&(rb.substr(rp-4,4)=="0000") {{{#!if this.rb=rb.substr(0,rp-4), rp=rp-4 }}}}}} {{{#!if (rp>2)&&(rb.substr(rp-2,2)=="00") {{{#!if this.rb=rb.substr(0,rp-2), rp=rp-2 }}}}}} {{{#!if (rp>2)&&(rb.substr(rp-2,2)=="00") {{{#!if this.rb=rb.substr(0,rp-2), rp=rp-2 }}}}}} {{{#!if (rp>1)&&(rb.substr(rp-1,1)=="0") {{{#!if this.rb=rb.substr(0,rp-1), rp=rp-1 }}}}}}}}} 19~36번째 자리까지 계산한 경우 rp에 18을 더합니다. {{{#!if ps {{{#!if rp=rp+18 }}}}}} rb 정리를 이것으로 종료합니다. ##== 오류 코드 == error 1 : 오버플로 5 : 이중 소수점 표기 6 : 소수점 윗부분 오류 7 : 소수점 아랫부분 오류 warning 1 : 소수점 아래 입력한 자릿수가 너무 많음. ##== 아래 출력 변수 설명 == '''sa''' : searching a; '''sb''' : searching b; '''sf''' : searching f; '''rl''' : result string length to output; '''p''' : a point of string(s); ru는 계산결과에서 소수점 위 자리이므로, dot(.)이 나오지 않습니다. ##여기까지 주석(주석 아님) }}}{{{#!wiki style="font-weight: 300; font-size: 20px;" {{{#!if this.sa=(this.a!="")&&(this.a!=null), this.sb=(this.b!="")&&(this.b!=null), this.sf=(this.f=='+')||(this.f=='-')||(this.f=='*')||(this.f=='/') }}}{{{#!if !sa&&!sb&&!sf 변수를 입력하세요... }}}{{{#!if !(sa&&sb&&sf) ({{{#!if !sa a{{{#!if !sb||!sf , }}}}}}{{{#!if !sb b{{{#!if !sf , }}}}}}{{{#!if !sf f}}}를 입력하세요...)}}}{{{#!if sa&&sb&&sf {{{#!if (ea==0)&&(eb==0) {{{#!if as[0]!=45 @a@}}}{{{#!if as[0]==45 (@a@)}}} {{{#!if as.length>=20 [br]}}}{{{#!if f=='+' +}}}{{{#!if f=="-" -}}}{{{#!if f=="*" *}}}{{{#!if f=="/" /}}} {{{#!if bs[0]!=45 @b@}}}{{{#!if bs[0]==45 (@b@)}}} {{{#!if (bs.length>=20)||(as.length+bs.length>=30) [br]}}}= {{{#!if rs!="" }}}{{{#!if (f=="*")||(f=="/") @ns@{{{#!if rs!="" @rs@}}}}}}@ru@{{{#!if +rp>0 ##rb string, decimal point marking .@rb@{{{#!if ri!="" @ri@{{{#!if (f=='/')&&(tn="...") ...}}}}}}}}}}}}}}}{{{#!if ((wa>0)||(wb>0))&&(ea==0)&&(eb==0) [br]{{{#!wiki style="display: inline; text-shadow: 1px 1px 2px gray; " '''{{{#yellow [경고] }}}'''}}}변수 {{{#!if wa==1 a{{{#!if wb==1 와 }}}}}}{{{#!if wb==1 b}}}의 소수점 아래에 입력한 문구가 너무 많습니다. 소수점 아래 19번째 자리부터 입력된 문구는 무시됩니다. }}}{{{#!if (ea>0)||(eb>0) {{{#!if (ea==1)||(eb==1) '''{{{#orangered [오류]}}}''' 변수 {{{#!if ea==1 a{{{#!if eb==1 와 }}}}}}{{{#!if eb==1 b}}}에 너무 많은 값을 입력했습니다. {{{#gray (오버플로)}}}[br]}}}{{{#!if eb==3 '''{{{#orangered [오류]}}}''' 0으로 나눌 수 없습니다.[br]}}}{{{#!if (ea==5)||(eb==5) '''{{{#orangered [오류]}}}''' 변수 {{{#!if ea==5 a{{{#!if eb==5 와 }}}}}}{{{#!if eb==5 b}}}에 소수점이 2개 이상 입력되어 있습니다. {{{#gray (입력 오류)}}}[br]}}}{{{#!if (ea==6)||(eb==6) '''{{{#orangered [오류]}}}''' 변수 {{{#!if ea==6 a의 소수점 윗자리{{{#!if eb==6 와 }}}}}}{{{#!if eb==6 b의 소수점 윗자리}}}에 올바르지 않은 문구가 입력되어 있습니다. {{{#gray (입력 오류)}}}[br]}}}{{{#!if (ea==7)||(eb==7) '''{{{#orangered [오류]}}}''' 변수 {{{#!if ea==7 a의 소수점 아랫자리{{{#!if eb==7 와 }}}}}}{{{#!if eb==7 b의 소수점 아랫자리}}}에 올바르지 않은 문구가 입력되어 있습니다. {{{#gray (입력 오류)}}}[br]}}}}}}}}}