C# (Sharp) Programming Language Question:
Download Job Interview Questions and Answers PDF
Which .Gang of Four. design pattern is shown below?
Answers:
Answer #1<pre> public class A {
private A instance;
private A() {
}
public
static A Instance {
get
{
if ( A == null )
A = new A();
return instance;
}
}
}
</pre>
1. Factory
2. Abstract Factory
3. Singleton
4. Builder
private A instance;
private A() {
}
public
static A Instance {
get
{
if ( A == null )
A = new A();
return instance;
}
}
}
</pre>
1. Factory
2. Abstract Factory
3. Singleton
4. Builder
Answer #23
Download C# (Sharp) Programming Language Interview Questions And Answers
PDF