--- title: "Precision Multiplication" type: "article" slug: "precision-multiplication" url: "http://localhost/article/precision-multiplication/" markdown_url: "http://localhost/article/precision-multiplication.md" published_at: "2026-11-23T19:00:46+00:00" modified_at: "2026-11-23T19:00:46+00:00" featured_image: url: "http://localhost/wp-content/uploads/2022/04/20230809-041332.jpg" excerpt: "10 REM ****************************** Precision Multiplication ****************************** 20 PRINT \"Give number of digits:\" 30 INPUT \"In first term:\";m 40 INPUT \"In second term:\";n 50 LET k=m+n 52 DIM a(m) 54 DIM b(n) 56 DIM p(k) 58 PRINT 60 PRINT \"Give digits of first term\" 62 INPUT a$ 64 PRINT a$ 70 PRINT \"Give digits of second…" post_tag: - name: "Full Text" slug: "fulltext" taxonomy: "post_tag" url: "http://localhost/tag/fulltext/" - name: "TS 2068" slug: "ts2068" taxonomy: "post_tag" url: "http://localhost/tag/ts2068/" - name: "Type-in program" slug: "type-in-program" taxonomy: "post_tag" url: "http://localhost/tag/type-in-program/" model: - name: "Timex/Sinclair 2068" slug: "ts-2068" taxonomy: "model" url: "http://localhost/model/ts-2068/" indiv: - name: "Roald Schrack" slug: "roald-schrack" taxonomy: "indiv" url: "http://localhost/indiv/roald-schrack/" publication_r: id: 35941 title: "CATS Newsletter" type: "periodical" url: "http://localhost/periodical/cats-newsletter/" authors: "R.A. Schrack" volume: "3" issue: "2" issues_articles: - id: 39601 title: "CATS v3 n2" type: "issue" url: "http://localhost/issue/cats-v3-n2/" pages: "13" pubdate: "May 1985" archive_link: false --- # Precision Multiplication ``` 10 REM ****************************** Precision Multiplication ****************************** 20 PRINT "Give number of digits:" 30 INPUT "In first term:";m 40 INPUT "In second term:";n 50 LET k=m+n 52 DIM a(m) 54 DIM b(n) 56 DIM p(k) 58 PRINT 60 PRINT "Give digits of first term" 62 INPUT a$ 64 PRINT a$ 70 PRINT "Give digits of second term" 72 INPUT b$ 74 PRINT b$ 76 PRINT 80 FOR i=1 TO m 82 LET a(i)=VAL a$(m-i+1) 84 NEXT i 90 FOR i=1 TO n 92 LET b(i)=VAL b$(n-i+1) 94 NEXT i 100 FOR i=1 TO m 102 LET c=0 104 FOR j=1 TO n 106 LET q=a(i)*b(j)+c 108 LET c=INT (q/10) 110 LET p(i+j-1)=q-c*10+p(i+j-1) 112 LET d=INT (p(i+j-1)/10) 114 LET c=c+d 116 LET p(i+j-1)=p(i+j-1)-10*d 118 NEXT j 120 LET p(i+n)=c 122 NEXT i 130 PRINT "Product is:" 132 FOR i=k TO 1 STEP -1 134 IF (i=k) AND (p(i)=0) THEN GO TO 138 136 PRINT p(i); 138 NEXT i 140 STOP ``` R.A.Schrack ``` Give number of digits in terms 1 and 2 :30 and 41 Give digits of first term 241573142393627673576957439049 Give digits of second term 45994811347886846310221728895223 034301839 Product is: 11111111111111111111111111111111 11111111111111111111111111111111 1111111 ```