Interview Questions.

.NET Apps Interview Questions

fluid

.NET Apps Interview Questions

Q1. Why .NET Framework?

Ans: .NET Framework is the most impressive improvement stage for building different arrangements on Windows. For instance, utilizing the .NET Framework, you can make applications for Windows Desktop, Web applications, Windows Phone applications, Windows Store applications, Windows Server, Windows Azure (cloud) as well as Bot structures and mental administrations.

Q2. What is BCL?

Ans: The Base Class Library is a Common Language Infrastructure. BCL embodies an enormous number of normal functionalities which are accessible to every one of the .NET Languages. BCL makes the engineers life a lot less complex while carrying out different functionalities like I/O tasks, Data access activities, graphical UIs and connection points to different equipment gadgets by exemplifying them into different namespaces and classes. It likewise epitomizes the administrations which are expected by the most recent true applications. .NET Framework applications, parts and the controls are based on BCL.

Q3. Make sense of CLR, CTS, CLS under .NET Framework?

Ans: Common Language Runtime is one of the principal building blocks of Microsoft .NET Framework which is liable for performing different tasks under .NET Framework.

At the point when you plan the application utilizing Microsoft .NET dialects like C#.NET or VB.NET, the language has its own complier which assembles the code into normal configuration that is CIL [Common Intermediate Language]. Then CIL gets designated to CLR which thusly performs numerous tasks. It changes over CIL into Native code with the assistance of JIT.

CLR additionally performs different activities like Memory Management, Application Execution, Thread Management, Security checks, load the necessary congregations and their sorts. The code which is overseen by CLR is otherwise called Managed Code. Every one of the oversaw dialects are dealt with by a solitary runtime that is CLR.

Normal Type System (CTS) characterizes how the sorts are characterized and utilized in the Common Language Runtime. CTS gives cross-language mix, type security, and superior execution code execution. -

At the point when you characterize a number variable in VB.NET and proclaim number in C#.NET, both the dialects share a similar kind which is Int32, accessible under .NET Framework.

CTS characterizes rules which should be trailed by dialects to make objects written in one language callable in different dialects.

Microsoft .NET Framework gives different crude information types which can be utilized while creating applications utilizing different dialects.

Normal Language Specification (CLS) is a bunch of rules. CLS controls likewise characterize a subset of CTS. By characterizing parts utilizing CLS includes just, engineers are ensured to utilize these parts in the wide range of various dialects which are CLS consistent dialects. The majority of the kinds which are characterized under .NET structure are CLS grumbling.

Q4. What is an application server?

Ans: As characterized in Wikipedia, an application server is a product motor that conveys applications to client PCs or gadgets. The application server runs your server code. Some notable application waiters are IIS (Microsoft), WebLogic Server (BEA), JBoss (Red Hat), WebSphere (IBM).

Q5. What is a base class and inferred class?

Ans: A class is a layout for making an item. The class from which different classes infer essential usefulness is known as a base class. For example On the off chance that Class Y gets from Class X, Class X is a base class.

The class which gets usefulness from a base class is known as an inferred class. In the event that Class Y gets from Class X, Class Y is a determined class.

Q6. What is an extender class?

Ans: An extender class permits you to broaden the usefulness of a current control. It is utilized in Windows structures applications to add properties to controls.

Q7. What is legacy?

Ans: Inheritance addresses the connection between two classes where one sort gets usefulness from a subsequent kind and afterward expands it by adding new techniques, properties, occasions, fields and constants.

C# support two kinds of legacy:

Execution legacy

 Interface legacy

Q8. What is execution and point of interaction legacy?

Ans: When a class (type) is gotten from another class(type) to such an extent that it acquires every one of the individuals from the base sort it is Implementation Inheritance.

At the point when a sort (class or a struct) acquires just the marks of the capabilities from another kind it is Interface Inheritance.

Overall Classes can be gotten from another class, thus support Implementation legacy. Simultaneously Classes can likewise be gotten from at least one points of interaction. Thus they support Interface legacy.

Q9. What is legacy order?

Ans: The class which gets usefulness from a base class is known as an inferred class. An inferred class can likewise go about as a base class for another class. Subsequently it is feasible to make a tree-like design that represents the connection between completely related classes. This design is known as the legacy order.

Q10. How would you keep a class from being acquired?

Ans: In VB.NET you utilize the NotInheritable modifier to keep developers from involving the class as a base class. In C#, utilize the fixed watchword.

Q11. Name Different Types of Constructors in C#?

Ans: There are four unique kinds of constructors you can write in a class -

Default Constructor

Defined Constructor

Duplicate Constructor

Static Constructor

Q12. Characterize Overriding?

Ans: Overriding is an idea where a strategy in a determined class utilizes a similar name, return type, and contentions as a technique in its base class. As such, on the off chance that the determined class contains its own execution of the strategy as opposed to involving the technique in the base class, the cycle is called superseding.

Q13. Might you at any point involve different legacy in .NET?

Ans: .NET backings just single legacy. Anyway the intention is achieved utilizing numerous points of interaction.

Q14. For what reason don't we have different legacy in .NET?

Ans: There are a few purposes behind this. In basic words, the endeavors are more, benefits are less. Various dialects have different execution prerequisites of numerous legacy. So to execute various legacy, we want to concentrate on the execution parts of the relative multitude of dialects that are CLR consistent and afterward carry out a typical strategy of executing it. This is a lot of endeavors. Besides different point of interaction legacy particularly covers the advantages that various legacy has.

Q15. What is an Interface?

Ans: A point of interaction is a norm or agreement that contains just the marks of techniques or occasions. The execution is finished in the class that acquires from this connection point. Points of interaction are fundamentally used to set a typical norm or agreement.

Q16. What are occasions and delegates?

Ans: An occasion is a message sent by a control to inform the event of an activity. Anyway it isn't realized which article gets the occasion. Consequently, .NET gives an extraordinary sort called Delegate which goes about as a mediator between the source item and beneficiary article.

Q17. What is business rationale?

Ans: It is the usefulness which handles the trading of data among data set and a UI.

Q18. What is a part?

Ans: Component is a gathering of sensibly related classes and strategies. A part is a class that executes the IComponent connection point or uses a class that carries out IComponent interface.

Q19. What is a control?

Ans: A control is a part that gives UI (UI) capacities.

Q20. What are configuration designs?

Ans: Design designs are normal answers for normal plan issues.

Q21. What is an association pool?

Ans: An association pool is a 'assortment of associations' which are divided among the clients mentioning one. When the association is shut, it gets once again to the pool. This permits the associations with be reused.

Q22. What is a level document?

Ans: A level document is the name given to message, which can be perused or composed just successively.

Q23. What are useful and non-practical necessities?

Ans: Functional necessities characterizes the way of behaving of a framework while non-practical prerequisites determine how the framework ought to act; as such they indicate the quality necessities and judge the way of behaving of a framework.

For example

Practical - Display a graph which shows the greatest number of items sold in a district.

Non-utilitarian - The information introduced in the outline should be refreshed like clockwork.

Q24. What is an Assembly?

Ans: A get together is a last deployable unit which can formed and got. The gathering can likewise be named as a reusable assortment of types and assets which cooperate as a legitimate unit of functionalities in .NET. .NET gatherings can be planned as executable (.EXE) or reusable part (.DLL). A gathering contains at least one oversaw types which can be made open to the unit or outside the unit.

Get together gets separated into four unique parts.

Manifest.

Type Metadata.

Moderate Language.

Assets.

Q25. Make sense of various kinds of Assemblies?

Ans: The various kinds of Assemblies are as per the following:

Manifest - contains data about the get together like Version of a gathering, the public key in the event that the gathering is shared get together and the way of life data. It likewise contains the security requests to confirm this gathering. CLR utilizes the manifest to stack the gathering.

Type Metadata - gives the total data about the sorts which are accessible in the gathering like Class, Structure, Interface, Enum, and the techniques, their boundaries. The compilers naturally produce this metadata. You can utilize this Type Metadata to powerfully stack the sorts utilizing .NET Reflection.

Middle Language - It a code created by the language explicit compiler. It is otherwise called Machine autonomous code which can be incorporated on one machine and can be sent on another. CLR focuses on this code to JIT to change over it into processor rely upon code which can be additionally executed.

Assets - Assembly can likewise contain the inserted assets like symbols, pictures, string tables media cuts.

You can see this data utilizing a .NET structure utility called ILDASM.EXE

Microsoft .NET help various kinds of congregations.

•    Confidential Assembly - Private Assemblies are the gatherings which are simply known to the application to which it has been referred to. Naturally, the gatherings are dependably private when you make and reference them. The confidential gathering gets put away in the application organizer which is utilizing the get together.

Confidential gatherings are related to the assistance of name of a get together and form of a gathering. In any case, the renditions doesn't exactly come into the image as the referred to gathering is in a similar organizer of your application.

•    Shared/Global/Public Assembly - Global/Public Assemblies are the congregations which are shared across different applications. These gatherings are introduced into Global Assembly Cache which goes about as a common region for every one of the congregations.

Worldwide Assembly is related to the four-section gathering name - Name of an Assembly, Version of a get together, and Culture of an Assembly and Public Key Token of a gathering. Worldwide Assembly Cache can contain various variants of a gathering.

You can introduce a public/worldwide get together into Global Assembly Cache [GAC] utilizing GACUTIL.EXE instrument.

•    Satellite Assembly - Satellite Assemblies are utilized to fabricate multi-lingual congregations for applications. Satellite congregations contain data about the way of life. Satellite gatherings are utilized to show the information in various dialects as per Country/Region.

Q26. What is the worldwide get together store (GAC)?

Ans: GAC is a broad store of congregations that permits .NET applications to share libraries. GAC takes care of a portion of the issues related with dll's (DLL Hell).

Q27. What is a stack? What is a store?

Ans: Stack is a spot in the memory where worth sorts are put away. Pile is a spot in the memory where the reference types are put away.

Q28.What is instrumentation?

Ans: It is the capacity to screen an application with the goal that data about the application's advancement, execution and status can be caught and detailed.

Q29.What is code audit?

Ans: The most common way of inspecting the source code commonly through a friend, to check it against best practices.

Q30. What is logging?

Ans: Logging is the most common way of continuing data about the situation with an application.

Q31. What are models?

Ans: Mock-ups are a bunch of plans as screens, graphs, depictions and so on, that confirms the plan and procure input about the application's prerequisites and use cases, at a beginning phase of the plan interaction.

Q32. What is a Form?

Ans: A structure is a portrayal of any window showed in your application. Structure can be utilized to make standard, borderless, drifting, modular windows.

Q33. What is a various report interface(MDI)?

Ans: A UI compartment that empowers a client to work with more than each record in turn. For example Microsoft Excel.

Q34. What is a solitary report interface (SDI) ?

Ans: A UI that is made to oversee graphical UIs and controls into single windows. For example Microsoft Word

Q35. What is BLOB ?

Ans: A BLOB (parallel enormous item) is a huge thing like a picture or an exe addressed in paired structure.

Q36. What is ClickOnce?

Ans: ClickOnce is another sending innovation that permits you to make and distribute self-refreshing applications that can be introduced and run with insignificant client communication.

Q37. What is object job displaying (ORM) ?

Ans: It is an intelligent model for planning and questioning data set models. There are different ORM devices in the market like CaseTalk, Microsoft Visio for Enterprise Architects, Infagon and so on.

Q38. What is a confidential get together?

Ans: A confidential gathering is neighborhood to the establishment index of an application and is utilized simply by that application.

Q39. What is a common get together?

Ans: A common get together is kept in the worldwide gathering store (GAC) and can be utilized by at least one applications on a machine.

Q40. What is the contrast among client and custom controls?

Ans: User controls are more straightforward to make while custom controls require additional work.

Client controls are utilized when the design is static though custom controls are utilized in unique formats.

A client control can't be added to the tool kit though a custom control can be.

A different duplicate of a client control is expected in each application that utilizes it though since custom controls are put away in the GAC, just a solitary duplicate can be utilized by all applications.

41.Where do custom controls live?

In the worldwide get together store (GAC).

Q42. What is an outsider control ?

Ans: An outsider control is one that isn't made by the proprietors of a venture. They are typically used to save time and assets and reuse the usefulness created by others (outsider).

Q43. What is a double formatter?

Ans: Binary formatter is utilized to serialize and deserialize an article in twofold arrangement.

Q44. What is Boxing/Unboxing?

Ans: Boxing is utilized to change over esteem types to protest.

For example int x = 1;

object obj = x ;

Unpacking is utilized to change over the article back to the worth kind.

For example int y = (int)obj;

Boxing/unpacking hushes up a costly activity.

Q45. What is a COM Callable Wrapper (CCW)?

Ans: CCW is a covering made by the normal language runtime(CLR) that empowers COM parts to get to .NET items.

Q46. What is a Runtime Callable Wrapper (RCW)?

Ans: RCW is a covering made by the normal language runtime(CLR) to empower .NET parts to call COM parts.

Q47. What is a computerized signature?

Ans: A computerized mark is an electronic mark used to check/gurantee the personality of the person who is sending the message.

Q47. What is trash assortment and make sense of its various ages?

Ans: Garbage gatherer is a piece of Common Language Runtime, which does programmed memory the executives for your application. At the point when you make an article in your application, CLR allots the memory for that item on Managed Heap.

City worker gives number of advantages like -

Programmed Memory Management - You can construct your application without pondering how to free the memory as Garbage Collector gets called naturally by CLR.

Trash specialist does capable memory the board for your items.

Trash specialist does programmed recover of the memory for those articles which are not being used and which are set apart for cancellation.

Trash specialist distributes the memory for objects so that one article can not utilize other item information accidently.

Q48. Make sense of the distinction among oversaw and unmanaged code.

Ans: Managed code is a code made by the .NET compiler. It doesn't rely upon the design of the objective machine since it is executed by the CLR (Common Language Runtime), and not by the working framework itself. CLR and overseen code offers designers few advantages, similar to trash assortment, type checking and exemptions taking care of.

Then again, unmanaged code is straightforwardly arranged to local machine code and relies upon the design of the objective machine. It is executed straight by the working framework. In the unmanaged code, the engineer needs to ensure he is managing memory use and distribution (particularly on account of memory spills), type security and special cases physically.

In .NET, Visual Basic and C# compiler makes oversaw code. To get unmanaged code, the application must be written in C or C++.

Q49. Make sense of what LINQ is.

Ans: LINQ is an abbreviation for Language Integrated Query, and was presented with Visual Studio 2008. LINQ is a bunch of elements that stretches out question capacities to the .NET language sentence structure by adding sets of new standard inquiry administrators that permit information control, no matter what the information source. Upheld information sources are: .NET Framework assortments, SQL Server data sets, ADO.NET Datasets, XML archives, and any assortment of items that help IEnumerable or the conventional IEnumerable<T> interface, in both C# and Visual Basic. So, LINQ overcomes any issues between the universe of items and the universe of information.

Q50. What do the accompanying abbreviations in .NET represent: IL, CIL, MSIL, CLI and JIT?

Ans: IL, or Intermediate Language, is a CPU free somewhat incorporated code. IL code will be ordered to local machine code utilizing current ecological properties by Just-In-Time compiler (JIT). JIT compiler makes an interpretation of the IL code to a gathering code and uses the CPU design of the objective machine to execute a .NET application. In .NET, IL is called Common Intermediate Language (CIL), and in the early .NET days it was called Microsoft Intermediate Language (MSIL).

CLI, or Common Language Infrastructure, is an open detail created by Microsoft. It is a gathered code library utilized for sending, forming, and security. In .NET there are two CLI types: process gatherings (EXE) and library congregations (DLL). CLI gatherings contain code in CIL, and as referenced, during accumulation of CLI programming dialects, the source code is converted into CIL code as opposed to into stage or processor explicit item code.

To sum up:

When assembled, source code is first meant IL (in .NET, that is CIL, and recently called MSIL).

CIL is then gathered into a bytecode and a CLI get together is made.

Before code execution, CLI code is gone through the runtime's JIT compiler to produce local machine code.

The PC's processor executes the local machine code.

Q51. What number of dialects are upheld by .NET at present time?

Ans: When .NET was presented first time, it upholds numerous dialects like VB.NET,C#,COBOL, and Perl and so forth. At present time it upholds just about 44 dialects.




CFG