কম্পিউটার টিউটোরিয়াল

C# MathF.Exp() মেথড উদাহরণসহ

C#-এ MathF.Exp() মেথডটি e (ইউলার সংখ্যা, প্রায় ২.৭১৮) কে নির্দিষ্ট পাওয়ারে তোলার ফলাফল রিটার্ন করে, অর্থাৎ eval।

সিনট্যাক্স

public static float Exp (float val);

উদাহরণ ১

বড় পাওয়ারের কারণে Infinity রিটার্ন করেছে।

using System;

class Demo {
    public static void Main(){
        float val = 90f;
        float res = MathF.Exp(val);
        Console.WriteLine("MathF.Exp() = " + res);
    }
}

আউটপুট

MathF.Exp() = Infinity

উদাহরণ ২

০ পাওয়ারের ফলাফল ১।

using System;

class Demo {
    public static void Main(){
        float val = 0.00f;
        float res = MathF.Exp(val);
        Console.WriteLine("MathF.Exp() = " + res);
    }
}

আউটপুট

MathF.Exp() = 1
  1. C#-এ MathF.Sin() মেথড: ফ্লোট সাইন ফাংশন ব্যবহার

  2. C#-এ MathF.Truncate() মেথড উদাহরণসহ

  3. C#-এ MathF.Tanh() মেথড উদাহরণসহ

  4. C#-এ MathF.Tan() মেথড উদাহরণসহ