Pascal's triangle: Difference between revisions

m
Line 346:
<syntaxhighlight lang="Amazing Hopper">
#include <jambo.h>
#define Mulbyandmoveto(_X_) Mul by '_X_', Move to '_X_'
 
Main
Line 354 ⟶ 355:
Set 'c' To str, Move to 'r'
Loop if ( var 'j' Is less than 'i' )
Set 'i' Minus 'j', Plus one 'j', Div it,; Mul by 'c',and Movemove to 'c'
CatMulti (cat ' r, Cat ( "\t", Str(c) ) ),'; Move to 'r'
++j
Back
Line 365 ⟶ 366:
{{out}}
<pre>
$ hopper jm/pascal.jambo 1514
1
1 1
Line 380 ⟶ 381:
1 12 66 220 495 792 924 792 495 220 66 12 1
1 13 78 286 715 1287 1716 1716 1287 715 286 78 13 1
 
1 14 91 364 1001 2002 3003 3432 3003 2002 1001 364 91 14 1
</pre>
 
543

edits