SlideShare a Scribd company logo
1 of 7
 Define CLR and lists its component
The Common Language Runtime(CLR), the virtual machine component of Microsoft's .NET framework, manages theexecution of .NET programs.
A process known as just-in-timecompilation converts compiled code into machine instructions which the computer's CPU then executes. The CLR
prov ides additional services including memory management, type safety, exception handling, garbagecollection, security and thread management. All
programs written f or the .NET f ramework, regardless of programming language, are executed by the CLR.
There are 4 main components of .Net Framework.
 CLR(Common Language Runtime)
 CTS(Common type system)
 BCL(Base Class Library)
 CLS(Common Language Specification)
 Is it possible to have two main methods in C#-justify
Yes - y ou can specif y custom entry point if you hav e multiple Main methods.This option specifies the class that contains the entry point to the program,
if more than one class contains a Main method.
using System;
using System.Collections.Generic;
using System.Text;
namespace Multiple_MainClasses
{
class A
{
static void Main(string[] args)
{
Console.WriteLine("I am from Class A");
Console.ReadLine();
}
}
class B
{
static void Main(string[] args)
{
Console.WriteLine("I am from Class B");
Console.ReadLine();
}
}
}
 Name the compiler used for C# and lists its type.
 Visual C#
 Visual C#
 Mono
 Portable.NET
 Sharp Develop
 Roslyn
 List out the application that is supported by .NET
•ASP.Net Web applications
•Web services
•Windows applications
•Windows services
•Console applications
•Mobile applications
•Class libraries
 Depict the role of garbage collection in .NET
The Garbagecollection is very important techniqueinthe.Netframeworkto freetheunusedmanaged codeobjects in the memory
and free thespaceto theprocess. The garbagecollection (GC) is new featurein Microsoft .net framework. When we have a class
that represents an object in theruntimethatallocates a memory space in the heap memory, the behavior ofthat objects can be
done in the allotted memory in the form of heap. The heap memory is divided into number ofgenerations. Normally it is three
generations.The Generation0 is for shortlive objects, Generation 1is for medium liveobjects whicharemovedfrom Generation 0.
Generation 3 is mostly stableobjects. Thegarbagecollection uses an algorithm which checks the objects in the generation, the
objects life time get over then it will be removed from the memory.
 Define boxing and Un boxing
In C#, all the value types are derived from the class object. So, a reference variable of type object can refer to any other value type. C# introduces two
methods to Boxing and Unboxing, which links value type to reference type. The basic difference between Boxing and Unboxing is that Boxing is the
conversion of the value type to an object type whereas, on other hands, the term Unboxing refers to the conversion of the object type to the value
type.
int i =24;
object ob =i; // Box the integer type n into object type ob.
int j =(int) ob; // Unbox the integer value stored in object type ob to integer
 List out the Types of Data in C# with diagrammatic representation
 List out the escape sequence in c# also list out there uses.
 Name the predefined reference type.
 Name some C# preprocess directive.
The preprocessor directives give instruction to the compiler to preprocess the information before actual compilation starts.All
preprocessor directives begin with #, and only white-space characters may appear beforea preprocessordirective ona line. Preprocessor
directives arenot statements, so they donot endwitha semicolon(;).C#compilerdoes not havea separatepreprocessor; however, the
directives are processed as ifthere was one. In C#the preprocessor directives are used to help in conditional compilation.
#define
It defines a sequence ofcharacters, called symbol.
#undef
It allows you to undefine a symbol.
#if
It allows testing a symbol or symbols to see ifthey evaluate to true.
#else
It allows to create a compound conditional directive, along with #if.
#elif
It allows creating a compound conditional directive.
#endif
Specifies the end ofa conditional directive.
#line
It lets you modify the compiler's line number and (optionally) the file name output for errors and warni ngs.
#error
It allows generating an error from a specific location in your code.
#warning
It allows generating a level one warning from a specific location in your code.
#region
It lets you specify a block ofcodethatyou canexpand orcollapsewhen using the outlining featureoftheVisualStudio Code Editor.
#endregion
It marks the end ofa #region block.
 Describe in Detail the object oriented features of C#
Oops known as object-oriented programming languagesystem is themain featureofC#whichfurthersupports themajor features ofoops
including:
 Abstraction.
 Encapsulation.
 Inheritanceand.
 Polymorphism.
 Illustrate the .NET architecture with a diagram and explain in detail components.
.NET is tiered, modular, and hierarchal. Each tier of the .NET Framework is a layer of abstraction. .NET languages are the top tier and the most
abstracted level. The common language runtime is the bottom tier, the least abstracted, and closest to the native environment. This is important
since the common language runtime works closely with the operating environment to manage .NET applications. The .NET Framework is partitioned
into modules, each with its own distinct responsibility. Finally, since higher tiers request services only from the lower tiers, .NET is hierarchal. The
architectural layout of the .NET Framework is illustrated in Figure
 Define role of CTS and list various languages supported by C#
In Microsoft's.NET Framework, the Common Type System (CTS) is a standard that specifies how type definitions and specific
valuesof types are represented in computer memory. It isintendedto allow programswritten in different programming languag es
to easily share information.
Talking about the languages .NET framework support; infact there are many(some 22, 23 lang uages)Some of them are:Visual Basic, C#, C++, Python, COBOL,
Jscript, Eiffel, Java, Haskell, Pascal, ML, Ada, APL, C, C++, Perl, SmallTalk, Oberon, Scheme, Mercury, Oz, RPG, Objective Camlto name some of them
 Factorial and square root of given number
 Fibonacci number generation
 Call By value and call by reference with example./ Demonstrate Ref and out parameters
 Demonstrate method overloading with example.
 Why xml comments are used in c#
 explain the use of foreach loop in c#
 Explain the use of Null coalescing operator?
 What is namespace? What are the members of namespace?
 What is the difference between Method overriding and method hiding ?
 What is the difference between structure and class?
 Compare between abstract class and interfaces
 What is delegate?
 Briefly explain exception handling in C# with example
C# note

More Related Content

What's hot

What's hot (19)

Csharp4 basics
Csharp4 basicsCsharp4 basics
Csharp4 basics
 
C, C++ Interview Questions Part - 1
C, C++ Interview Questions Part - 1C, C++ Interview Questions Part - 1
C, C++ Interview Questions Part - 1
 
c# at f#
c# at f#c# at f#
c# at f#
 
Unit 1 question and answer
Unit 1 question and answerUnit 1 question and answer
Unit 1 question and answer
 
CSharp Presentation
CSharp PresentationCSharp Presentation
CSharp Presentation
 
C notes.pdf
C notes.pdfC notes.pdf
C notes.pdf
 
C# in depth
C# in depthC# in depth
C# in depth
 
C programming interview questions
C programming interview questionsC programming interview questions
C programming interview questions
 
C#unit4
C#unit4C#unit4
C#unit4
 
2. data, operators, io
2. data, operators, io2. data, operators, io
2. data, operators, io
 
Overview of c language
Overview of c languageOverview of c language
Overview of c language
 
C vs c++
C vs c++C vs c++
C vs c++
 
Top C Language Interview Questions and Answer
Top C Language Interview Questions and AnswerTop C Language Interview Questions and Answer
Top C Language Interview Questions and Answer
 
Learn C# Programming - Decision Making & Loops
Learn C# Programming - Decision Making & LoopsLearn C# Programming - Decision Making & Loops
Learn C# Programming - Decision Making & Loops
 
C Course Material0209
C Course Material0209C Course Material0209
C Course Material0209
 
Python Interview questions 2020
Python Interview questions 2020Python Interview questions 2020
Python Interview questions 2020
 
Presentation on C++ programming
Presentation on C++ programming Presentation on C++ programming
Presentation on C++ programming
 
Computer programming questions
Computer programming questionsComputer programming questions
Computer programming questions
 
C# - Part 1
C# - Part 1C# - Part 1
C# - Part 1
 

Similar to C# note

Similar to C# note (20)

C# Unit 1 notes
C# Unit 1 notesC# Unit 1 notes
C# Unit 1 notes
 
C# AND F#
C# AND F#C# AND F#
C# AND F#
 
C sharp
C sharpC sharp
C sharp
 
1.Philosophy of .NET
1.Philosophy of .NET1.Philosophy of .NET
1.Philosophy of .NET
 
Introduction to programming using c
Introduction to programming using cIntroduction to programming using c
Introduction to programming using c
 
C#_01_CLROverview.ppt
C#_01_CLROverview.pptC#_01_CLROverview.ppt
C#_01_CLROverview.ppt
 
A tour of C# - Overview _ Microsoft Learn.pdf
A tour of C# - Overview _ Microsoft Learn.pdfA tour of C# - Overview _ Microsoft Learn.pdf
A tour of C# - Overview _ Microsoft Learn.pdf
 
Session2 (3)
Session2 (3)Session2 (3)
Session2 (3)
 
Dot net
Dot netDot net
Dot net
 
LEARN C# PROGRAMMING WITH GMT
LEARN C# PROGRAMMING WITH GMTLEARN C# PROGRAMMING WITH GMT
LEARN C# PROGRAMMING WITH GMT
 
CSharpCheatSheetV1.pdf
CSharpCheatSheetV1.pdfCSharpCheatSheetV1.pdf
CSharpCheatSheetV1.pdf
 
interview questions.docx
interview questions.docxinterview questions.docx
interview questions.docx
 
Components of .NET Framework
Components of .NET FrameworkComponents of .NET Framework
Components of .NET Framework
 
Csharp
CsharpCsharp
Csharp
 
Mit4021 c# and .net
Mit4021   c# and .netMit4021   c# and .net
Mit4021 c# and .net
 
Let's us c language (sabeel Bugti)
Let's us c language (sabeel Bugti)Let's us c language (sabeel Bugti)
Let's us c language (sabeel Bugti)
 
Interoduction to c++
Interoduction to c++Interoduction to c++
Interoduction to c++
 
.Net framework components by naveen kumar veligeti
.Net framework components by naveen kumar veligeti.Net framework components by naveen kumar veligeti
.Net framework components by naveen kumar veligeti
 
.Net slid
.Net slid.Net slid
.Net slid
 
Common language runtime clr
Common language runtime clrCommon language runtime clr
Common language runtime clr
 

More from Dr. Somnath Sinha (9)

Introducing CSS Selectors.docx
Introducing CSS Selectors.docxIntroducing CSS Selectors.docx
Introducing CSS Selectors.docx
 
Difference between Servlet and JSP.docx
Difference between Servlet and JSP.docxDifference between Servlet and JSP.docx
Difference between Servlet and JSP.docx
 
Data structure design in SE
Data structure  design in SEData structure  design in SE
Data structure design in SE
 
Panel view
Panel viewPanel view
Panel view
 
Ppt 2
Ppt 2Ppt 2
Ppt 2
 
Security
SecuritySecurity
Security
 
Mob ppt
Mob pptMob ppt
Mob ppt
 
black hole attack
black hole attackblack hole attack
black hole attack
 
File 1
File 1File 1
File 1
 

Recently uploaded

CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxJiesonDelaCerna
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for BeginnersSabitha Banu
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxiammrhaywood
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatYousafMalik24
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTiammrhaywood
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfUjwalaBharambe
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...M56BOOKSTORE PRODUCT/SERVICE
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxEyham Joco
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsanshu789521
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentInMediaRes1
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupJonathanParaisoCruz
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,Virag Sontakke
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxRaymartEstabillo3
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdfssuser54595a
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxsocialsciencegdgrohi
 

Recently uploaded (20)

CELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptxCELL CYCLE Division Science 8 quarter IV.pptx
CELL CYCLE Division Science 8 quarter IV.pptx
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 
Full Stack Web Development Course for Beginners
Full Stack Web Development Course  for BeginnersFull Stack Web Development Course  for Beginners
Full Stack Web Development Course for Beginners
 
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptxECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
ECONOMIC CONTEXT - PAPER 1 Q3: NEWSPAPERS.pptx
 
Earth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice greatEarth Day Presentation wow hello nice great
Earth Day Presentation wow hello nice great
 
OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...OS-operating systems- ch04 (Threads) ...
OS-operating systems- ch04 (Threads) ...
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPTECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
ECONOMIC CONTEXT - LONG FORM TV DRAMA - PPT
 
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdfFraming an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
Framing an Appropriate Research Question 6b9b26d93da94caf993c038d9efcdedb.pdf
 
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
KSHARA STURA .pptx---KSHARA KARMA THERAPY (CAUSTIC THERAPY)————IMP.OF KSHARA ...
 
Types of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptxTypes of Journalistic Writing Grade 8.pptx
Types of Journalistic Writing Grade 8.pptx
 
Presiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha electionsPresiding Officer Training module 2024 lok sabha elections
Presiding Officer Training module 2024 lok sabha elections
 
Meghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media ComponentMeghan Sutherland In Media Res Media Component
Meghan Sutherland In Media Res Media Component
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
MARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized GroupMARGINALIZATION (Different learners in Marginalized Group
MARGINALIZATION (Different learners in Marginalized Group
 
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,भारत-रोम व्यापार.pptx, Indo-Roman Trade,
भारत-रोम व्यापार.pptx, Indo-Roman Trade,
 
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
 
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
18-04-UA_REPORT_MEDIALITERAСY_INDEX-DM_23-1-final-eng.pdf
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
 

C# note

  • 1.  Define CLR and lists its component The Common Language Runtime(CLR), the virtual machine component of Microsoft's .NET framework, manages theexecution of .NET programs. A process known as just-in-timecompilation converts compiled code into machine instructions which the computer's CPU then executes. The CLR prov ides additional services including memory management, type safety, exception handling, garbagecollection, security and thread management. All programs written f or the .NET f ramework, regardless of programming language, are executed by the CLR. There are 4 main components of .Net Framework.  CLR(Common Language Runtime)  CTS(Common type system)  BCL(Base Class Library)  CLS(Common Language Specification)  Is it possible to have two main methods in C#-justify Yes - y ou can specif y custom entry point if you hav e multiple Main methods.This option specifies the class that contains the entry point to the program, if more than one class contains a Main method. using System; using System.Collections.Generic; using System.Text; namespace Multiple_MainClasses { class A { static void Main(string[] args) { Console.WriteLine("I am from Class A"); Console.ReadLine(); } } class B { static void Main(string[] args) { Console.WriteLine("I am from Class B"); Console.ReadLine(); } } }  Name the compiler used for C# and lists its type.  Visual C#  Visual C#  Mono  Portable.NET  Sharp Develop  Roslyn  List out the application that is supported by .NET •ASP.Net Web applications •Web services •Windows applications •Windows services •Console applications
  • 2. •Mobile applications •Class libraries  Depict the role of garbage collection in .NET The Garbagecollection is very important techniqueinthe.Netframeworkto freetheunusedmanaged codeobjects in the memory and free thespaceto theprocess. The garbagecollection (GC) is new featurein Microsoft .net framework. When we have a class that represents an object in theruntimethatallocates a memory space in the heap memory, the behavior ofthat objects can be done in the allotted memory in the form of heap. The heap memory is divided into number ofgenerations. Normally it is three generations.The Generation0 is for shortlive objects, Generation 1is for medium liveobjects whicharemovedfrom Generation 0. Generation 3 is mostly stableobjects. Thegarbagecollection uses an algorithm which checks the objects in the generation, the objects life time get over then it will be removed from the memory.  Define boxing and Un boxing In C#, all the value types are derived from the class object. So, a reference variable of type object can refer to any other value type. C# introduces two methods to Boxing and Unboxing, which links value type to reference type. The basic difference between Boxing and Unboxing is that Boxing is the conversion of the value type to an object type whereas, on other hands, the term Unboxing refers to the conversion of the object type to the value type. int i =24; object ob =i; // Box the integer type n into object type ob. int j =(int) ob; // Unbox the integer value stored in object type ob to integer  List out the Types of Data in C# with diagrammatic representation  List out the escape sequence in c# also list out there uses.
  • 3.  Name the predefined reference type.  Name some C# preprocess directive. The preprocessor directives give instruction to the compiler to preprocess the information before actual compilation starts.All preprocessor directives begin with #, and only white-space characters may appear beforea preprocessordirective ona line. Preprocessor directives arenot statements, so they donot endwitha semicolon(;).C#compilerdoes not havea separatepreprocessor; however, the directives are processed as ifthere was one. In C#the preprocessor directives are used to help in conditional compilation. #define It defines a sequence ofcharacters, called symbol. #undef It allows you to undefine a symbol. #if It allows testing a symbol or symbols to see ifthey evaluate to true. #else It allows to create a compound conditional directive, along with #if. #elif It allows creating a compound conditional directive. #endif Specifies the end ofa conditional directive. #line It lets you modify the compiler's line number and (optionally) the file name output for errors and warni ngs. #error It allows generating an error from a specific location in your code. #warning It allows generating a level one warning from a specific location in your code. #region It lets you specify a block ofcodethatyou canexpand orcollapsewhen using the outlining featureoftheVisualStudio Code Editor. #endregion It marks the end ofa #region block.  Describe in Detail the object oriented features of C# Oops known as object-oriented programming languagesystem is themain featureofC#whichfurthersupports themajor features ofoops including:  Abstraction.  Encapsulation.  Inheritanceand.  Polymorphism.  Illustrate the .NET architecture with a diagram and explain in detail components. .NET is tiered, modular, and hierarchal. Each tier of the .NET Framework is a layer of abstraction. .NET languages are the top tier and the most abstracted level. The common language runtime is the bottom tier, the least abstracted, and closest to the native environment. This is important since the common language runtime works closely with the operating environment to manage .NET applications. The .NET Framework is partitioned into modules, each with its own distinct responsibility. Finally, since higher tiers request services only from the lower tiers, .NET is hierarchal. The architectural layout of the .NET Framework is illustrated in Figure
  • 4.  Define role of CTS and list various languages supported by C# In Microsoft's.NET Framework, the Common Type System (CTS) is a standard that specifies how type definitions and specific valuesof types are represented in computer memory. It isintendedto allow programswritten in different programming languag es to easily share information. Talking about the languages .NET framework support; infact there are many(some 22, 23 lang uages)Some of them are:Visual Basic, C#, C++, Python, COBOL, Jscript, Eiffel, Java, Haskell, Pascal, ML, Ada, APL, C, C++, Perl, SmallTalk, Oberon, Scheme, Mercury, Oz, RPG, Objective Camlto name some of them  Factorial and square root of given number  Fibonacci number generation  Call By value and call by reference with example./ Demonstrate Ref and out parameters  Demonstrate method overloading with example.  Why xml comments are used in c#  explain the use of foreach loop in c#
  • 5.  Explain the use of Null coalescing operator?  What is namespace? What are the members of namespace?  What is the difference between Method overriding and method hiding ?  What is the difference between structure and class?
  • 6.  Compare between abstract class and interfaces  What is delegate?  Briefly explain exception handling in C# with example