Interview FAQs


FAQs of level

Here is the some c# interfaces-

  • System.Math
  • System.Convert
  • System.Net.Dns
  • System.Web.Configuration.WebConfigurationManager
  • System.Linq.Enumerable
  • System.Web.SessionState.SessionStateUtility
  • System.Web.SiteMap

Letters are represented in a computer by numeric codes. When the computer sees a code of 100 (decimal), it represents a lowercase "d".
We commonly refer to character encoding as a letters "ASCII value". 
ASCII (American Standard Code for Information Interchange) is a 7-bit standard that has been around since the late 1950s (its current incarnation dates from 1968). It defines 128 different characters, which is more than enough for English: upper- and lowercase letters, punctuation, numerals, control codes , and non printing codes such as tab, return, and backspace. 
Unicode fixes the limitations of ASCII and ANSI, by providing enough space for over a million different symbols. Like the above two systems, each character is given a number, so that Russian ? is 042F, and the Korean won symbol ? is 20A9. (Note that all Unicode numbers are Hexadecimal, meaning that one counts by 16s not 10s, not a problem as users really donot need to know the mapping numbers anyway.) So, although not yet totally comprehensive, Unicode covers most of the world’s writing systems. Most importantly, the mapping is consistent, so that any user anywhere on any computer has the same encoding as everyone else, no matter what font is being used.
So Unicode is a map, a chart of (what will one day be) all of the characters, letters, symbols, punctuation marks, etc. necessary for writing all of the worlds languages past and present.

A multidimensional array is simply one that uses multiple indices to access its elements. You might specify a position using two coordinates, x and y. You want to use these two coordinates as indices. A two-dimensional array such as this is declared as follows:
<baseType>[ , ] <name>;
Arrays of more dimensions simply require more commas:
<baseType>[ , , , ] <name>;
int[,] myarray = new int[2,2]; // declaration
public void test()
myarray[0, 0] = 1; // initialization
myarray[0, 1] = 2;
myarray[1, 0] = 3;
myarray[1, 1] = 4; // initialization
foreach (int x in myarray)

There are some assembly benefits-

  • Assemblies are designed to simplify application deployment and to solve versioning problems that can occur with component-based applications.
  • End users and developers are familiar with versioning and deployment issues that arise from today component-based systems. Some end users have experienced the frustration of installing a new application on their computer, only to find that an existing application has suddenly stopped working. Many developers have spent countless hours trying to keep all necessary registry entries consistent in order to activate a COM class.
  • Many deployment problems have been solved by the use of assemblies in the .NET Framework. Because they are self-describing components that have no dependencies on registry entries, assemblies enable zero-impact application installation. They also simplify uninstalling and replicating applications.

Construction: When an object is first instantiated it needs to be initialized. This initialization is known as construction and is carried out by a constructor function, often referred to simply as a constructor for convenience.

Program p = new Program(); // creating object of program class
Destruction: When an object is destroyed, there are often some clean-up tasks to perform, such as freeing memory. This is the job of a destructor function, also known as a destructor.
Program p1 = new Program("testing"); // passing value to constructor

A string is basically a sequence of characters. The string type has the following characteristics:

It is a reference typeIt is a common misconception that string is a value type. That is because its immutability makes it act sort of like a value type. It actually acts like a normal reference type.

It is immutableYou can never actually change the contents of a string, at least with safe code which does not use reflection. Because of this, you often end up changing the value of a string variable. For instance, the code s = s.Replace ("foo", "bar"); does not change the contents of the string that s originally referred to - it just sets the value of s to a new string, which is a copy of the old string but with "foo" replaced by "bar".

It can contain nullsC programmers are used to strings being sequences of characters ending in "\0", the null or null character. (I will use "null" because that is what the Unicode code chart calls it in the detail; do not get it confused with the null keyword in C# char is a value type, so can not be a null reference!) In .NET, strings can contain null characters with no problems at all as far as the string methods themselves are concerned. However, other classes (for instance many of the Windows Forms ones) may well think that the string finishes at the first null character - if your string ever appears to be truncated oddly, that could be the problem.

It overloads the == operatorWhen the == operator is used to compare two strings, the Equals method is called, which checks for the equality of the contents of the strings rather than the references themselves. For instance, "hello".Substring(0, 4)=="hell" is true, even though the references on the two sides of the operator are different (they refer to two different string objects, which both contain the same character sequence). Note that operator overloading only works here if both sides of the operator are string expressions at compile time - operators are not applied polymorphically. If either side of the operator is of type object as far as the compiler is concerned, the normal == operator will be applied, and simple reference equality will be tested.

  • C# and Java are both languages descended from C and C++.
  • Each includes advanced features, like garbage collection, which remove some of the low level maintenance tasks from the programmer. In a lot of areas they are syntactically similar.
  • Both C# and Java compile initially to an intermediate language: 
  • C# to Microsoft Intermediate Language (MSIL), and Java to Java bytecode.
  • In each case the intermediate language can be run by interpretation or just-in-time compilation - on an appropriate virtual machine. In C#, however, more support is given for the further compilation of the intermediate language code into native code. 
  • Like Java, C# gives up on multiple class inheritance in favor of a single inheritance model. C# supports the multiple inheritance of interfaces.

PreviousDisplaying 25 of 25
Need Help? Contact Us.

Log in


Forgot password?


New User