Polynomial long division: Difference between revisions
Content added Content deleted
m (→{{header|Wren}}: Minor tidy) |
(→{{header|jq}}: representation) |
||
Line 2,492: | Line 2,492: | ||
'''Adapted from the second version in the [[#Wren|Wren]] entry.''' |
'''Adapted from the second version in the [[#Wren|Wren]] entry.''' |
||
In this entry, |
In this entry, the polynomial of degree n, SIGMA c[i] * x^(n-i), is represented by |
||
the JSON array c. |
|||
in the task description; that is, using jq notation, `.[$i]` corresponds to |
|||
the coefficient of {\displaystyle x^i}. |
|||
<syntaxhighlight lang=jq> |
<syntaxhighlight lang=jq> |
||
# Emit the canonical form of the polynomical represented by the input array |
# Emit the canonical form of the polynomical represented by the input array |