Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- namespace Comparing_floats
- {
- class Program
- {
- static void Main(string[] args)
- {
- double first = double.Parse(Console.ReadLine());
- double second = double.Parse(Console.ReadLine());
- double eps = 0.000001;
- if (Math.Abs(first - second) < eps)
- {
- Console.WriteLine("True");
- }
- else
- {
- Console.WriteLine("False");
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement