I am Subracting two Double Variable numbers getting 0 as output But for Some other values I am getting output as like this -2.98023E-08 why it is happening

internally computers will get a small fraction as a result.

have a look here and also for some solution approaches: