Junior .NET Developer
10+ Junior .NET Developer Interview Questions and Answers for Freshers
Q1. Coding round 1. Write a code for prime and odd numbers
Code for prime and odd numbers
For prime numbers, check if the number is divisible by any number less than itself
For odd numbers, check if the number is not divisible by 2
Use loops and conditional statements to implement the checks
Consider edge cases such as negative numbers and 0
Q2. What is the SQL query to retrieve the maximum salary from a database?
SQL query to retrieve the maximum salary from a database
Use the SELECT statement with the MAX function to retrieve the maximum salary
Specify the column name for the salary field in the table
Example: SELECT MAX(salary) FROM employees
Q3. What are the available access modifiers in programming?
Access modifiers control the visibility and accessibility of classes, methods, and variables in programming.
Public - accessible from anywhere
Private - accessible only within the same class
Protected - accessible within the same class and its subclasses
Internal - accessible within the same assembly
Protected Internal - accessible within the same assembly or subclasses
Q4. What are the key concepts of Object-Oriented Programming (OOP)?
Key concepts of OOP include encapsulation, inheritance, polymorphism, and abstraction.
Encapsulation: Bundling data and methods that operate on the data into a single unit (class). Example: Class with private fields and public methods.
Inheritance: Creating new classes based on existing classes, inheriting their attributes and behaviors. Example: Subclass extending a superclass.
Polymorphism: Objects of different classes can be treated as objects of a common superclass. Example:...read more
Q5. What is the difference between procedures and functions?
Procedures do not return a value, while functions return a value.
Procedures are used to perform an action, while functions are used to calculate and return a value.
Functions have a return type specified, while procedures do not.
Example: Procedure to display a message on the screen vs Function to calculate the sum of two numbers.
Q6. What is your understanding of normalization in SQL?
Normalization in SQL is the process of organizing data in a database to reduce redundancy and improve data integrity.
Normalization is a technique used to eliminate redundant data and ensure data integrity.
It involves breaking down a table into smaller tables and defining relationships between them.
There are different normal forms such as 1NF, 2NF, 3NF, and BCNF.
For example, in a database of students and courses, instead of storing student details in the course table, a separa...read more
Share interview questions and help millions of jobseekers 🌟
Q7. Write a code for reverse string
Code to reverse a string
Create an empty string variable to store the reversed string
Loop through the original string from the end to the beginning
Append each character to the empty string variable
Return the reversed string
Q8. Difference between substr() and charindex()?
substr() extracts a substring from a string based on start and length, while charindex() finds the position of a character or substring within a string.
substr() is used in SQL Server to extract a portion of a string based on the starting position and length.
charindex() is used in SQL Server to find the position of a specific character or substring within a string.
Example: SELECT SUBSTRING('Hello World', 1, 5) will return 'Hello'.
Example: SELECT CHARINDEX('o', 'Hello World') w...read more
Junior .NET Developer Jobs
Q9. write schema for many to many relationship
Schema for many to many relationship
Create a junction table to connect the two entities
Each record in the junction table represents a relationship between the two entities
Both entities have a many-to-many relationship with each other
Q10. 3. Write a code for fibannoci series
Code for Fibonacci series
Declare two variables to store the first two numbers of the series
Use a loop to generate the next numbers in the series by adding the previous two
Print or store the generated numbers
Q11. What is class and object?
A class is a blueprint for creating objects, while an object is an instance of a class.
A class defines the properties and behaviors of objects.
An object is created based on a class, and can have its own unique values for the properties defined in the class.
Example: Class 'Car' may have properties like 'color' and 'model', while an object of class 'Car' could be 'red Ferrari'.
Q12. What is datatype?
Datatype is a classification of data which tells the compiler or interpreter how the programmer intends to use the data.
Datatypes specify the type of data that a variable can hold.
Examples include int (integer), string (text), bool (boolean), etc.
Different programming languages have different datatypes and rules for their usage.
Q13. What is inheritance?
Inheritance is a concept in object-oriented programming where a class inherits properties and behaviors from another class.
Allows for code reusability by creating a new class based on an existing class
Derived class (child class) inherits attributes and methods from a base class (parent class)
Example: Class Car can inherit properties like color and methods like drive from class Vehicle
Q14. What is array
An array is a collection of similar data types stored in contiguous memory locations.
Arrays can be of any data type, including integers, floats, and objects.
Arrays are indexed starting from 0.
Arrays can be multidimensional, such as a 2D array.
Arrays can be dynamically resized using methods like Append or Resize.
Example: string[] names = {"John", "Jane", "Bob"};
Q15. diff btw c# and java
C# is a language developed by Microsoft for the .NET framework, while Java is a language developed by Sun Microsystems.
C# is primarily used for Windows development, while Java is platform-independent.
C# uses properties and events, while Java uses getter and setter methods.
C# has delegates and events for event handling, while Java uses interfaces and classes.
C# has LINQ for querying data, while Java has streams and lambdas.
C# has automatic memory management with garbage collec...read more
Q16. All oops concept
Object-oriented programming concepts like inheritance, encapsulation, polymorphism, and abstraction.
Inheritance: Allows a class to inherit properties and behavior from another class.
Encapsulation: Bundling data and methods that operate on the data into a single unit.
Polymorphism: Ability to present the same interface for different data types.
Abstraction: Hiding the complex implementation details and showing only the necessary features.
Interview Questions of Similar Designations
Top Interview Questions for Junior .NET Developer Related Skills
Interview experiences of popular companies
Calculate your in-hand salary
Confused about how your in-hand salary is calculated? Enter your annual salary (CTC) and get your in-hand salary
Reviews
Interviews
Salaries
Users/Month