Closed briandowns closed 1 year ago
Hmm interesting, we can use -
as a prefix operator rather than a function call for negating a number - do you think we need this as a method?
const x = 100;
print(-x); // - 100
Probably unnecessary then. I'll defer to you if you want it in the language. I'm happy to close the PR if you don't. 😀
Appreciate the PR but I think we probably don’t need it
Cool, cool. Closing.
Add negate method to number type
Resolves: #
What's Changed:
Adds a new method,
negate
, to the number type.Type of Change:
#
Housekeeping:
#
Screenshots (If Applicable):