Answer Posted / srinivasa reddy
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace InterfaceExample
{
interface IA
{
void MethodA();
}
class Program : IA
{
static void Main(string[] args)
{
IA InterfaceA = new Program();
InterfaceA.MethodA();
Console.ReadKey();
}
void IA.MethodA()
{
Console.WriteLine("This is a test");
}
}
}
Is This Answer Correct ? | 6 Yes | 4 No |
Post New Answer View All Answers
What is collection of classes in c#?
Why do we use threads in c#?
What is byte c#?
Is multilevel inheritance possible in c#?
How many bytes is an int in c#?
In a C# class we have a SortedList member m_addinProjects
we want to provide an iterator to allow the consumer of
this class access to the items in the collection. Please
provide an iterator method for the AnalyzeAddinsDLL class
below and an example of how it would be used.
namespace AnalyzeAddinsDLL
{
public class AllAddInProjects
{
private SortedList
What is final keyword in c#?
How you will create satellite assemblies?
Is c# pass by value?
what happens if you inherit multiple interfaces and they have conflicting method names?
What is the data provider name to connect to access database?
Is c# used for frontend or backend?
Distinguish between a class and struct?
What is the difference between internal and protected in c#?
Can we extend sealed class in c#?