Is Floating Point Type - CSharp Language Basics

CSharp examples for Language Basics:Float

Description

Is Floating Point Type

Demo Code


using System.Reflection;
using System.Linq;
using System.Collections.Generic;
using System;//from  ww  w . ja v a 2  s  .co  m

public class Main{
        public static bool IsFloatingPoint(this Type type)
      {
         return type == typeof (float) || type == typeof (double);
      }
}

Related Tutorials