Static Static Method Same Class C# with Example



Static Static Method Same Class C# with Example

 	using System;

	namespace CSharpClass{
		class StaticMethod {
			static void Main(String[] arg){
				int total = add(10, 20);
				Console.WriteLine("Total of 10+20: " + total);
			}
			
			static int add(int x, int y){
				return x+y;
			}
		}
	}
 

0 Comment's

Comment Form

Submit Comment