Why doesn't it show -1 | Sololearn: Learn to code for FREE!
¡Nuevo curso! ¡Todo programador debería aprender IA Generativa!
Prueba una lección gratuita
19th Feb 2024, 3:05 PM
Sadhv Nonu
Sadhv Nonu - avatar
1 Respuesta
0
The square root of -1 is a complex number. That is what the output tells you. When working with float numbers, keep in mind the limits of floating point precision.
19th Feb 2024, 3:17 PM
Lisa
Lisa - avatar