Add signum to tuple.
This commit is contained in:
parent
2f24ae3250
commit
6a0edb873b
|
@ -48,6 +48,12 @@ struct Tuple(*T)
|
|||
return self if gcd == 0
|
||||
{ self[0]//gcd, self[1]//gcd}
|
||||
end
|
||||
|
||||
def signum
|
||||
{% begin %}
|
||||
{ {% for t, i in T %} self[{{i}}].signum, {% end %} }
|
||||
{% end %}
|
||||
end
|
||||
end
|
||||
|
||||
struct Number
|
||||
|
|
Loading…
Reference in New Issue
Block a user