spec/support/models/expression/baskara.rb in danica-2.7.4 vs spec/support/models/expression/baskara.rb in danica-2.7.5
- old
+ new
@@ -1,12 +1,13 @@
+# frozen_string_literal: true
+
module Danica
class Expression::Baskara < Expression.build(:a, :b, :c) { numerator / denominator }
-
private
def numerator
- negative(b) + Wrapper::PlusMinus.new(squared_root(delta))
+ negative(b) + Wrapper::PlusMinus.new(squared_root(delta))
end
def denominator
number(2) * a
end
@@ -14,6 +15,5 @@
def delta
power(b, 2) - multiplication(4, a, c)
end
end
end
-