Most Asked Dot Net Interview Questions

Software Development | Design, Digital, Technology | Oct 21,2021 | By Nikita Dhiman

It is critical for everyone to have a thorough grasp of the IT sector since it will have a significant impact on their future employment. This post will provide information on the top ten most often asked.Net Interview questions.

1.What exactly is CTS?

ANS:The Common Type System (CTS) is an acronym for Common Type System. It adheres to a set of defined rules that dictate how a data type should be declared and used in programme code. It's used to list all of the data types that will be used in the application. Following the rules in the CTS, we can develop our own classes and functions. It allows other programming languages to call the data type described in one programming language.

2.Explain CLS ?

ANS:The Common Language Specification (CLS) enables application developers to employ inter-language compatible components by following specific guidelines. It also facilitates code reuse across all.NET-compatible languages.

3.What exactly is JIT?

ANS:Just In Time (JIT) is an acronym for "just in time." During execution, it is a compiler that translates intermediate code into the native language.

4.What's the difference between an int and a 32-bit integer?

ANS:The only distinction between int and Int32 is that they are both integers. In the C# programming language, int is an alias name for Int32, which is a type offered by the.NET framework.

5.Describe the distinctions between value and reference types.

ANS:The following are the main distinctions between value and reference types: A reference type contains a pointer that contains the address of another memory location that has the actual data, whereas a value type contains the actual data immediately within the memory region. The contents of the value type are stored on the stack memory, whereas the contents of the reference type are stored on the heap memory. Assigning a value type variable to another variable copies the value directly, whereas assigning a reference variable to another generates a second copy of the reference rather than copying the value.

6.Explain Intermediate Microsoft Language

ANS:MSIL stands for Microsoft Intermediate Language, and it contains instructions for calling methods, managing memory, saving and initialising data, and handling exceptions, among other things. MSIL provides platform-independent instructions that are generated from source code by a language-specific compiler. Based on the requirement, the JIT compiler translates the MSIL into machine code.

7.What is an assembly, exactly?

ANS:An assembly is a file created by the compiler that contains a collection of types and resources that are designed to work together to build a logical unit of functionality. Assembly is also referred to as a compiled and logical unit of code. Executable (.exe) and dynamic link library (.dll) files are used to implement assemblies.

8.Is there a difference between ASP and ASP.NET? If so, could you describe how?

ANS:Yes, ASP.NET and ASP(Active Server Pages) are two separate programming languages. Let's have a look at how they differ from one another. ASP.NET makes use of.NET languages like C# and VB.NET, which are compiled to Microsoft Intermediate Language (MICL) (MSIL). VBScript is used by ASP. ASP code is interpreted while it is being executed. Microsoft's ASP.NET technology is used to create dynamic web apps, whereas ASP is Microsoft's server-side technology for creating web pages. ASP.NET is entirely object-oriented, whereas ASP is just somewhat so. For convenient data sharing, ASP.NET offers full XML support, whereas ASP has no built-in XML support.

9.What is the function of a garbage collector?

ANS:Garbage collector clears memory of unused code objects. There are three generations in the memory heap: Generation 0: It stores objects that have a brief lifespan. Generation 1: It stores items with a medium lifespan. Generation 2: This is for items with a long lifespan. The term "garbage collection" refers to the process of looking for objects in the managed heap's generations that are no longer in use by the application. It also reclaims their memory by performing the necessary operations. In order to free up memory, the garbage collector must complete a collection.

10.What exactly is caching?

ANS:Caching refers to temporarily storing data in memory so that a programme may easily access it rather than having to hunt for it in its original place. It improves an application's speed and performance efficiency.

11.In.NET, what is a delegate?

ANS:A delegate is a.NET object that can provide a function as a parameter and defines a method signature. Delegate always refers to a method that has the same signature as it. A delegate object can be used to encapsulate the reference to a method. The referenced method will be called when the delegate object is passed into a programme. Delegate can be used to create a custom event in a class.

12.What is the difference between boxing and unpacking in.NET?

ANS:The process of immediately transforming a value type into a reference type is known as boxing. Boxing is a given. Unboxing is the process of converting a reference type to a value type. The act of unboxing is explicit.

13.In the.NET framework, what is the purpose of manifest?

ANS:The metadata of the assembly is stored in the manifest. It contains metadata that is necessary for a variety of purposes, as listed below: Version information for the assembly. Checking the assembly's scope. Validation of classes by reference. Identification for security purposes

14.What does CAS stand for in.NET?

ANS:In order to restrict unauthorised access to programmes and resources during runtime, Code Access Security (CAS) is required. It is intended to address the concerns that arise from receiving code from third-party sources, which may contain bugs and vulnerabilities that expose the user's system to risk.Instead of delivering all operations at once, CAS provides limited access to code to perform only selected activities. CAS is a component of Microsoft's native.NET security framework.

15.What types of memories does the.NET framework support?

ANS:In.NET, there are two types of memories. They are as follows: Stack is a stored-value type that keeps track of each running thread and its current location. It is used to allocate static memory. Heap: A heap is a sort of stored reference that maintains track of more specific items or data. It is used to allocate dynamic memory.

16.Explain the differences between localization and globalisation.

ANS:The process of adapting our application to act according to the present culture and locality is known as localization. The process of creating an application so that it can be utilised by users from all over the world by supporting many languages is known as globalisation.

17.What are the parameters that control the behaviour of connection pooling?

ANS:The connection pooling characteristics are controlled by four factors. They are as follows: Timeout for connecting Pool Minimum Dimension Pool Size Maximum Pooling

18.What is the difference between MDI and SDI?

ANS:MDI (Several Document Interface) is a term that refers to a system that allows multiple documents to be An MDI is a multi-window interface that has one parent window and as many child windows as you like. The parent window's components, such as the toolbar and menubar, are shared. SDI (Single Document Interface): SDI creates a distinct window for each document. Each window has its own set of components, such as a toolbar and a menubar. As a result, it is not restricted to the parent window.

19.Describe the various components of an assembly?

ANS:The following are the various components of an assembly: Manifest — This file contains information about an assembly's version. Assembly metadata is another name for it. Metadata is a type of data that contains binary information about a programme MSIL stands for Microsoft Intermediate Language. Resources – This section contains a list of related files.

20.In.NET, describe role-based security.

ANS:Security measures in.NET are implemented using role-based security, which is based on the roles allocated to users in the organisation. Users are authorised within the organisation based on their jobs. Administrators, users, and guests, for example, have different levels of access in Windows.

A2N Academy aims to develop job-ready individuals with cutting-edge skillsets. Take a look at their most popular IT courses. Enroll in their dot NET Course right now.

Interested in working with IT companies?

Speak with us today

Do you have career gap?

Are you planning to shift your career?