0% found this document useful (0 votes)
20 views

Interview Questions(.NET)

The document outlines a comprehensive interview syllabus for .NET and related technologies, covering topics such as C#, ASP.NET, MVC, ADO.NET, Web API, and various frameworks and tools. It includes specific interview questions for each topic, focusing on concepts, performance tuning, and best practices. Additionally, it addresses certifications and tools relevant to the .NET ecosystem.

Uploaded by

dhanvikaxerox
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

Interview Questions(.NET)

The document outlines a comprehensive interview syllabus for .NET and related technologies, covering topics such as C#, ASP.NET, MVC, ADO.NET, Web API, and various frameworks and tools. It includes specific interview questions for each topic, focusing on concepts, performance tuning, and best practices. Additionally, it addresses certifications and tools relevant to the .NET ecosystem.

Uploaded by

dhanvikaxerox
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as TXT, PDF, TXT or read online on Scribd
You are on page 1/ 11

***************************************************

Dotnet(.NET)Interview Syallabus & Questions

****************************************************
Topics/ Full Stack to be Covered
------------------------------------------------
1)C# and OOPS.
2)ASP.NET.
3)MVC/SOLID Principles/Design Patterns.
4)ADO.NET/Entity Framework/N-Hiberante.
5)Web Services/WCF/WEB API/Micro-services.
6)Javascript/JQuery/Angular-JS/React-JS.
7)DB(SQL SERVER)-Questions/Queries.
8)TFS/Bit-Bucket.
9)JIRA/Agile Methodology Implementation.
10).NET CORE (.NET 5/.NET6).
11)SONAR QUABE (Code Quality Tool)
12)JENKINS-(For Deployements)etc.
13)AUTOSYS(For-Job running)--->Time Scheduling jobs).
14)CLOUD(AWS/AZURE/AZURE-DEVOPS/CI-CD/TERRAFORM)
15)CSM Certification/ AWS Associate ARCHITECT Certification/Safe Aglist/PMP
Certification.
16)ARCHITECTIRE TOOLS.--LIKE Lucid charts and Visio.
17)SNOWFLAKE
___________________________________________________________________________________
__________________
MVC- Interview Questions
---------------------------------
1)What is Convention Based and Attribute based routing--What is the Difference
between them?- ChatGPT
2)How to handle Errors in Middle of MVC application--?
3)How the Controls Move from One Page to another Page in MVC--?
4)Difference between Action filters and Http handlers/http modules --?
5)Strongly type view and Weak typed View in MVC--?
6)How to save and stored Client side data and how to save and stored at server side
data --?
7)what is Anti-forgery token--?
8)Logging Mechanism followed in your Project--? how ..?log4net
9)How to secure MVC application--?
10)how to improve Performance in MVC application & Dotnetcore application--?
11)Design Patterns and Types--? Creational pattern like -singelton etc- behavioural
nand stuructural patterns
12)difference between Keep and peek--in secessions in MVC-->
13)CDN In MVC--?
14)Data binding In MVC--?
15)Diff between view model & Multiple model
___________________________________________________________________________________
___________________________
--------------------------------------
WCF Interview Questions
-------------------------------------
1)How to test WCF application--? using SVC.util.exe -file
2)Is it possible to host the WCF service through web.config--? NO
3)Transactions in WCF--? Done
4)How to handle Exceptions in wcf--?Done
5)Custom bindings-
6)What is Poison Message (or) Poison Contract--?---done
7)Specifications in WCF--?done
8)Components in WCF--?done
9)What is "MAC" in wcf--?
"Message Authentication Code."
It is a cryptographic code that is used to verify the integrity of a message and
ensure that it has not been tampered with during transmission.
10)How "Event logging" is done in wcf--?
11)"Throtting Behaviour" in wcf service--?
12)what are the various Programming approaches for wcf--?
13)what are dead letter queues--?
14)what is fault contract in wcf--?
15)how to track logs in wcf--?-log4 n3t
16)Performence in wcf--? like
Choose Appropriate Binding:
17)Difference between WCF/WEBAPI/REST API/RESTFUL API --?
18)Connection Pooling in WCF--?--just like as throttling--
Connection pooling is an effective way to optimize database access in your WCF
services.
___________________________________________________________________________________
______________________________________
WEB API Interview Questions
-------------------------------------
1)Difference between HttpGet and Http post --?
HttpGet method is used to retrieve data from the server. When you send a HttpGet
request to a resource endpoint, you are requesting information from the server, and
the server responds with the requested data.
Ex:- GET /api/products

The HttpPost method is used to send data to the server for processing, typically to
create or update a resource on the server. When you send a HttpPost request, you
are instructing the server to perform a specific action based on the data you
provide.

POST /api/products
Request Body: {"name": "New Product", "price": 29.99}

2)Difference between Get and Post --?


3)Performance tunning in webapi--?
4)WEB API Architecture--?
5)JWT Authentication--?
6)web api calling using c#--?
7)Different ERROR Modes--?
8)Is Http Status Codes,Error Modes are same (or) different--?
9)How to handle exception in webapi --?
10)Difference between WEBAPI/REST API/RESTFUL API --? which is better and which
purpose is used which--?
11)Content Negotiation in web api --?
12)Fautures in webapi--?
13)CORS
14)Principles of RESTFul wepapi--? why we go for rest api specifically--?
15)Return Types in web API--?
Void.
Primitive type or Complex type.
HttpResponseMessage.
IHttpActionResult.

16)Exception Handling in Web API--?/Global exception handling--?


17)How to maintain Security in web API--?o auth
18)Content Negotiation in WEb api--?
19)Http Client factory..?
20)Difference between post and patch--? all http-
The POST method is used to create a new resource on the server.
The PATCH method is used to make a partial update to an existing resource on the
server.
In summary, POST is used for creating new resources, while PATCH is used for making
partial updates to existing resources.

verbs like get,put,post and delete


____________________________________________________________________

--------------------------------------
ASP.NET Interview Questions
-------------------------------------
1)How can we say that- Master Page & Aspx Page--?
2)How to Enable View State & Auto Post back--?
3)what is viewstate--?where u have written in viewstate--?
4)
___________________________________________________________________________________
_________________________
--------------------------------------
ADO.NET and ENTITY FRAMEWORK and LINQ Interview Questions
-------------------------------------
1)Difference between "Dataset" and "Data Adaptor" --?
2)Difference between "Connection Oriented" and "Dis-Connected Oriented"
architecture and exampples--?
3)Is ADO>NET (or) Entity Framework --? which is fast and Better performeance---when
we used the sscenarios--?
4)Difference between "ADO.NET" and "Entity Framework" --?
5)Data bound Controls--?
6)Difference between "Parameterised" and "Non-Parameterised" query --?
7)Code Optimization Tecniques for Dotnet --?
8)Events associated with Grid View Control --?
9)Difference between "Dataset" and "Data Reader" --? which is fast and which is
good --?
10)Difference between "Execute Scalar" and "Execute Reader" --?
11)Differences between Data grid and Grid View --?
12)connection Oriented and Disconnected in ado.net--?
13)Difference between Dataset and Data adaptor-->
14)Events associated with Grid view Control..?
15)Difference between "Lazy Loading" and "Eager Loading"--Examples--?
16)Difference between "Code First" and "Data Base First" and " Model First"
approaches --? and examples--?
17)LINQ queries and Examples--?
18)Lambda Expressions and Examples ---?
19)what is "Explicit loading" --Example --?
20)CSDL( Conceptual Schema Definition Language )
21)SSDL (Storage Schema Definition Language )
22)MSDL (Mapping Schema Definition Language )
23)How to call Stored Procedure in Entiry Framework--?
24)Difference between " where" Clause and "Let" Clause--?
25)Difference between " I Enumerable " and "IQuerable" and "Enumerator"--?
26)How to upload file using Entity FRAMEWORK..?
27)How to do search using Entity framework--?
28)How to Join "2" Select Statements using Entity Framework--?
29)Is it possible to pass Multiple Stored Procedures single time using Entity
Framework--? how --?
30)Advantages and Disadvantages of Entity Framework--?
31)what is .EDMX file and what it Contains--?
32)How to Increase Performance of EF--?
33)Database Concurrency in EF =How to use it--?
34)Difference between "First" and "First or Default" in LINQ--?
35)Differences between Data grid and Grid View --?
36)Calling Stored Procedures using Entity Framework--?
===================================================================================
=================================
C# Interview Questions
-------------------------------------
1)Garbage Collector(In-Depth)--? --Book
2)Is it Possible to force start Garbage Collector--(in Code)--?
3)Abstraction and Encapsulation Differences & Which Scenario's used and where --
(with one real-time example)--?
4)Polymorphism --Pgm and Real-time example --?
5)Abstract class and Interfaces Differences --Pgm and Scneario --?
6)Sealed Class (Scenario & Pgm)--?Book
7)Partial Class(Scenario & Pgm)--?Book
8)Deligates and Different Types of Deligates --(Scenario & Pgm)--?Book
9)Uses of "New" Keyword --?
10)Uses of "Var" keyword --?
11)Exception Handling --(In-Depth)---?
12)Use of "Static" Keyword--?
13)Assemblies -Different Types of assemblies (In-depth)--?
14)DLL hell --?
15)What is Event bubbling--?
16)Extension Methods/Annonomys Methods/Lambda Expressions--?
17)Reflection--?
18)Benifis of using "String" --?
19)CLS (Common Language Specification)--?
20)CLR (Common Lnaguage Runtime)--?
21)JIT Complier( JUST IN TIME)---?
22)HTTP Handlers and HTTP Modules?
23)Generics used in Scenarios and Pgm ---?
24)What is "REF" and "OUT" Parameters and Differences --?
25)Multithreading (In-Depth)---?
26)Dispose and Finalize - Differences and uses--?
27)SOLID Principles ---?
28)"YIELD" Keyword in C# --and uses---?
29)Uses of "Dynamic" Keyword --?
30)Dependency Injection -- Which Scenario's used and where --(with real-time
example)--?
31)Design Patterns(Singleton,Abstract, Abstract Factory)
32)What is base class-?
33)what is "Value" Type and "Reference" Types and Differences --?
34)What is "this" keyword--? can we use "this" in static Method--?
35)Inheritance and Different Types of Inheritence--?
36)Acess Modifiers (In-depth)---?
37)Use of "using" Keyword--?
38)Difference between "I-Disposible" and "Ienumerable" and E-numerator---?
39)what is blocks --?
40)what is "Managed Code" and "Un-Managed Code"--?
41)Difference between "Strong" and "weak" named assemblies --?
42)Difference between - 3.0/3.5/4.0/4.5/dotnet 5/dotnet6 /.netcore --?
43)Diff between "Boxing" and un-Boxing"--?
44)Difference between "Array" and "Arraylist"--?
45)Difference between "Hashtable" and "Dictionaty" /"Hashmap" --?
46)Difference between "Var" and "dynamic"--?
47)what is In-line function---?
48)Task Parallel Library(TPL)---?
49)Difference between "Async" and "AWAIT"--? and where we can used in real time
Scenario's ---?
50)Generic Pointers and Types --?
51)ASyncronous calls in C#--?
52)what is "Unique" Data Type--? where we can use it--?
53)Constructor and it's Types--?
54)Virtual function-- ?
55)Abstract Function--?
56)Pointers --and Pgm --?
57)Destructor--?
58)Generic Deligates and Types--?
59)Method Overriding---?
60)OOPS 6.0 features--?
61)Diff between "LOcalisation" and "Globalization"--?
62)Diff between "String" and "String-builder"--?
63)Diff between "string" and "Int"--?
64)Diff between "Static" and "Singleton"--?
65)Diff between "Multiple Inheritence" and "Multi level Inheritence"--?
66)Diff between "In" and "As"--? where we can use it--?
67)Diff between "Int" and "Int32"--?
68)Shadowing in C# --?
69)TUPLE in C# --?
70)What is "enum"---? example--?
71)is "enum" is Value type (or) reference type--?
72)Diff between "stack" and "heap"--?
73)Diff between "struct" and "class"--?
74)Diff between "Constant" and "Readonly"--?
75)what is GAC--?
76)IS it Possible to Caught multiple exceptions in Catch block--?
77)Diff between "Explicit" and "Implicit" Interface Implementation--?
78)Diff between "Serialisation" and "De-serialization"--?
79)Custom Exception Handling--?
80)LOGGING Mechanism In ur Project-->
81)DEPENDENCY INJECTION (IOC CONTAINERS,REPOSITORY PATTERN).
82)SSL
83)Which Authentication/Authorisation used in Project --? OAuth/JWTToken Based-
84)Explain "Lazy Loading"---?
85)UNIT Test Cases ---Mocking Tool -(which tool is used) and how mocking doing db
objects in Code--?
86)What is "This" Keyword--? Can we used on Static Method--? Dairy
87)Acess Modifier to restrict Method for an Assembly--?Dairy
88)Strong and Weak named assemblies--?
89)what are nullable types- explain that nullable types-?
90)

------------------- Programs Questions-------------


1)FIND out "Second Highest" Numbers --Program--?
2)REcurrsive alphabet/word- Program--?
3)FIbonacci Series "---Program--?
4)Find out the string count like -"Narasimha"- now find out how many alphabets in
this string count & what are they suppose like n=1 ,a=3, r=1,s=1,i=1 m=1,h=1 etc
5)csharp-coding-standards.
Coding https://www.dofactory.com/csharp-coding-standards
https://www.c-sharpcorner.com/blogs/c-sharp-coding-guidelines-and-best-practices-
v10
https://blog.submain.com/coding-standards-c-developers-need/

https://ankitsharmablogs.com/csharp-coding-questions-for-technical-interviews/ ---
>Coding Interview Question & Answers.
https://www.c-sharpcorner.com/article/net-programing-interview-questions/

___________________________________________________________________________________
_________
--------------------------------------
SQL Interview Questions
-------------------------------------

https://data-flair.training/blogs/sql-join/

1)What is "Clustered Index" and "Non- Clustered Index" --? Scenario's.


2)Primary Key and Foriegn Key --? Unique key--? Differences--?
3)SQL Injection--?
4)Errors in SQL --?
5)How do you encrypt and decrypt the stored procedure --?

6)Triggers and how many Types of Triggers--? Sceanrio's--?


7)CTE (Common Table Expressions)--Indepth---?
8)How to debug the Stored procedure--?
9)Difference between Functions/User defined Function and Stored Procedures--?
10)How many levels maintained by stored Procedure--?
11)JOINS and Types of Joins--?
12)Writing Minimum Stored procedure -Like create,update,delete etc--?
13)Cursors--Types of Cursors--?
14)VIEWS- Types of views-?
15)UNION,UNION ALL, INTERSECT statements--?
16)What is aggregate functions--?
17)Difference between "varchar" and "nvarchar"---?
18)Transactions in SQL---?
19)ACID Properties in SQL ---?
20)Constraints in SQL--? Different Types--?
21)What is Magic tables and different types of magic tables--?
22)DML and DDL in SQL --?
23)Idenifiers in SQL --?
24)Transformation in SQL --?
25)MOD in sql --? Example--?
26)Performance tunning in sql --?example
27)User defined in sql --?
28)HIGHEST SALARIES -like (1st,4th,5th and nth) Queries--?
29)Locking in SQL--?
30)Difference between "Temperary table " and "Temperarory Result set" and "CTE"
/recursive CTE--?
31)How can we identify which select statements is executing slow in Stored
Procedure--?

33)SQL optimization Tecniques-?


34)Stored procedure Optimization Techniques--?
35)What is Composite key--?
36)Execution Plan in SQL --?
37)Difference between "Temperary table " and "Temperarory Varaiable"--?
38)Having clause in sql --?
39)Difference between "Temperary table " and "CTE"--?
40)Normalization and it's types--?
41)How can we know the table Size--? Dairy
42)How to count Total number of Databases in SQL Server..? Dairy
43)Number of Users connected to Database & how many users are actively executing
some task- Query --? Dairy
44)How can we find the total number of tables are present in SQL DB--?Dairy
45)Difference between Distinct and Group Clause--?
46)Can i remove the default Contraint Columns in SQL SERVER-->YES
47)Exception handling in SQL--?
48)Ranks in SQL --?
49)Ranks & Dense ranks in sql -?
50)NVL & NVL2 function differnce in sql-?
___________________________________________________________________________________
_________
--------------------------------------
Javascript & JQUERY Interview Questions
-------------------------------------

1)Difference between Var and My Var--?


2)Difference between window.browser and Dcoument.ready --?
3)

___________________________________________________________________________________
_________--------------------------------------------------
--------------------------------------
DOTNET CORE Interview Questions & Application Level
-------------------------------------
1)Single tone 3 types--?
2)Application Performance tuning--?
https://www.bytehide.com/blog/performance-optimization-tips-csharp
https://www.c-sharpcorner.com/UploadFile/skumaar_mca/tips-to-improve-the-
performance-in-Asp-Net-application/
3)Payment Gateway..?
4)

--------------------------------------------------------------------------

###################################################################################
############################################################

22-SEP-2023 (Wipro Interview )


-------------------------------------
1)what Architecture you followed in your Project --? Technical & Functional --?
2)Explain about Previous project in Functionally -Both Client & User aspects --?
3)HTTP handlers and Https Modules differences and it's role --?
https://www.codeproject.com/Articles/30907/The-Two-Interceptors-HttpModule-and-
HttpHandlers#HttpHandlertheextensionbasedpreprocessor
4)Difference between Action filters and Http handlers/http modules --?
5)Principles of RESTFul wepapi--? why we go for rest api specifically--?
6)Throtlling in WCF--?
7)what is Client side Data annotations and Servide side validations in MVC--?
8)How to save and stored Client side data and how to save and stored at server side
data --?
9)Strongly type view and Weak typed View in MVC--?

------------------------------------------------------------------------------

27-OCT-2023 (Capgemini Interview)

1)for ex:- Virtusa wil have acees for respective tables or records-if i have 20000
tables or records- unfortunately its delted- how can we trive back of all those=?
2)virtusa -we have acess to git hub- while cloning how can we identify whether its
dotnet or dotnet core
3)we have drop down- and gets populated number of pop-up's like 200 for ex:- same
time-
now how can we do and resoleve -requires to populate and sort in ascending order

------------------------------------------------------------------------------

1) Can you give me breif introduction about urself and about ur projects,areas of
technical expertise and roles and resposibilities
2)Approx-5-7 Mins here. to describe the above question.

1)Difference between Abstract Class and Interface-?which Scenario u used in ur


project..?
2)what is Garbage Collector--?
3)what is Deligates--how many types of deligates
4)what is SOLID Principles--?
5)can u explain what is Dependency Injection--?
6)Design patterns --which design pattern is used in ur project--tel me one scenario
u used this ?
6)Logging Mechanism followed in your Project--?
7)How you handled Errors in MVC application-
8)MVC page life cycle
9)what is Routing--?
10)how we can maintain secession in mvc--?

You worked on WCF and web api both right..?


ans- Yes.
11)What is the difference between web services wcf and web api--?
12)what is throlling in WCF--?
13)how can we handle errors in wcf--?
14)Difference between Http get and http post in wep api--?
15)Return types in wep api--?
16)what is CORS --?
17)how to debug webapi- which tool u used--?
18)what is lazy loading--?
19)which ORM is used in ur project
20)which is fast -ADO.NET(or) Entity Framework-?
18)how we can do performance tunning in stored procedure-?
19)How can we identify which select statements is executing slow in Stored
Procedure--?
20)what is CTE and tell me one scenario which u used--?
21)have u written any N-unit test cases--? which approach you followed then--?
22)
-----------------------------------------------------------------------------------
--------------------------
Net Cracker
----------------------------------------
1).Net Framework -in detail --?
NET Framework is a software development framework for building and running
applications on Windows.
.NET Framework is part of the .NET platform, a collection of technologies for
building apps for Linux, macOS, Windows, iOS, Android, and more.
2)MVC- Role & Responsiblities- role in MVC in current project-?
3)Diff between request & response cycle in server--?- Asp.net page ;ife cycle /MVC
life cycle
4)what are the types of state Managements--? asp/mvc
5)How state management is done in server-?
6)what are nullable types- explain that nullable types-?
7)Diff between ref and out--?
8)ACcess specifiers--?
9)Diff between static and declare method--?
10)Role of CLR--?
11)What is Platform Independent-?
12)what is boxig and unboxing-?
13)diff between view model & Multiple model--?
14)Diff between stored procedure and function-?
15)what are views-?
16)NVL & NVL2 function differnce in sql-?
17)Ranks & dense ranks in sql -?
18)Components in Dotnet-?
Components of . Net framework

Common Language Runtime (CLR),


Base Class Library (BCL),
Framework Class Library (FCL),
Common Type System (CTS),
Common Language Specification (CLS),
19)what are oops Concepts-?
20)Filters in MVC-?
------------------------------------------------------------------

1)Dependency Injection - where u have used in ur Project and Scenario and Syntax--?
// constructor injection
public class constructorinjection
{
private text _text;
public constructorinjection(text t1)
{
this._text = t1;
}
public void print()
{
_text.print();
}
}
2)What is difference between Transient--? Scoped and Single ton--? where u have
used in ur project scenario and Syntax-?--Service Life times

3)Design Patterns-? single ton and Abstarct Factory DEsign Patterns scenario in
project and Syntax-? where the intance is created inside the factory class
(Syntax)-?

Public sealed class Singleton1 {


private Singleton1() {}
private static Singleton1 instance = null;
public static Singleton1 Instance {
get {
if (instance == null) {
instance = new Singleton1();
}
return instance;
}
}
}
class LuxuryCar extends Car
{
LuxuryCar(Location location)
{
super(CarType.LUXURY, location);
construct();
}
@Override
protected void construct()
{
System.out.println("Connecting to luxury car");
}
}

4)which scenario u used abstarct class and Interface in ur project--? syntax-?


5)Deligates u used in ur project --?scenario and syntax-?
5)SOLID principles-?
Public class Apple
{
public virtual string GetColor()
{
return "Red";
}
}
public class Orange : Apple
{
public override string GetColor()
{
return "Orange";
}
}
}
6)Dotnet Framework-?
7)Deligates u used in project - and scanrio and syntax-?
8).net core basics
9)diffrence between wed services and WCF--?
10)what is async and await-? where u used in ur project scenario and syntax-?
11)what is tasks (TPL)-? if one task is failed how we can lock exception -how can
we know that one task is failed-?
12)IOC Containers- used in project (Autofac) etc-?
13)Auto Mapper-Part-
14)Exp in AZure -? or AWS-?
15)MVVM /WPF

___________________________________________________________________________________
_________

Cognizant Interview Question & Answers (27/12/2023)

#################################################
C#
##########
1)OOPS Concepts.
2)Difference between Abstract Class & Interface-?
3)Collections & Types of Collections-?
4)Deligates-? Types of Deligates-?
5)Task--?
6)Asynchronous Programming- Async & Await--?
7)Anonymous Methods-?

#######################
SQL SERVER
#################
1)Difference Between Primary Key & Unique Key-?
2)Identity Column and ways to find last Identity value-?
3)Transaction in SQL Server--?
4)Difference Between Function and Stored Procedure--?
5)Difference Between rank() and dense_rank()

#######################
ADO.NET & Entity Framework
#################
1)what is Data reader and Data Adaptor-? Difference between them--?
2)What is Entity Framework & it's advantages--?

#######################
MVC
#################
1)What are Action Filters in MVC--?
2)MVC Provides Action Filters- Output Cache,handle error ,Authorize--?
3)Explain what is Routing In MVC-? 3 segments for routing Importance--?
4)Difference between View & Partial View-?
5)Attribute based routing in MVC-?
6)Tempdata in MVC-?
7)Razor in MVC-?
8)what is Vlaidation Summary in MVC-?
9)What is Database first approach in MVC using Entity Framework-?
10)How to use view Bag-?
11)Difference between ViewBag & View Data-?

#######################
Coding
#################
1)How to remove duplicate Characters from a string-?
https://www.codevscolor.com/c-sharp-remove-duplicate-characters-from-string
2)write a query to retrieve Departments who have less then "2" employees working in
it-?
SELECT DEPARTMENT,COUNT(EmpID) as 'Empno' From EmployeeInfo GROUP BY DEPARTMENT
HAVING COUNT(EmpId)<2;
3)Nth Highest Salary-? (using Dense rank)
SELECT * FROM (SELECT emp_name, emp_salary, DENSE_RANK() OVER (ORDER BY emp_salary
DESC) AS r
FROM emp)
AS subquery
WHERE r = 3;
################################################################################

Dotnet(.NET)
(C#.NET,ASP.NET,MVC,ADO.NET,Entity framework,SQL Server,WCF,Web API &.NET Core)

You might also like