Data commit
This commit is contained in:
parent
7387c8f97b
commit
cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions
15
Task/Pascals-triangle/HicEst/pascals-triangle.hicest
Normal file
15
Task/Pascals-triangle/HicEst/pascals-triangle.hicest
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
CALL Pascal(30)
|
||||
|
||||
SUBROUTINE Pascal(rows)
|
||||
CHARACTER fmt*6
|
||||
WRITE(Text=fmt, Format='"i", i5.5') 1+rows/4
|
||||
|
||||
DO row = 0, rows-1
|
||||
n = 1
|
||||
DO k = 0, row
|
||||
col = rows*(rows-row+2*k)/4
|
||||
WRITE(Row=row+1, Column=col, F=fmt) n
|
||||
n = n * (row - k) / (k + 1)
|
||||
ENDDO
|
||||
ENDDO
|
||||
END
|
||||
Loading…
Add table
Add a link
Reference in a new issue