Jump to content

Numeric error propagation: Difference between revisions

m
→‎{{header|Kotlin}}: Removed stale comment showing wrong output value
m (→‎{{header|Kotlin}}: Fixed x2-y1-swap, c/f Java/Discussion)
m (→‎{{header|Kotlin}}: Removed stale comment showing wrong output value)
Line 1,141:
val x2 = Approx(200.0, 2.2)
val y2 = Approx(100.0, 2.3)
println(((x1 - x2).pow(2.0) + (y1 - y2).pow(2.0)).pow(0.5)) // => 111.80339887498948 ±2.938366893361004
}</lang>
{{out}}
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.