cognizant Dotnet interview Questions

Cognizant Dotnet interview Questions


Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution

Question. What is Deep copy and shallow copy?
Answer. Deep copy, copy the whole object and make a different object, it means it do not refer to the original object while in case of shallow copy the target object always refer to the original object and changes in target object also make changes in original object.

Question. how to Create custom collection?
Answer. using System.Collections namespace we can create the our custom collection classes.

Question. how to Bind grid with business obj?
Answer. return the dataset or datatable from business object and assign to datasource of grid.

Question. What is Singleton and how to implement locking in singleton pattern?
Answer. Singleton pattern usage a class which can contain only one object through out the application.

class my_Singleton
{
private static my_Singleton obj;
protected my_Singleton
{
}
public static my_Singleton Instance()
{
lock{
if (obj == null)
{
obj= new my_Singleton();
}
}
return obj;
}
}

Question. What is Typed dataset?
Answer. typed dataset is a normal dataset having property to data type check for Colum values and can access the columns by column names.

Question. What is Using keyword?
Answer. using keyword can be used in two format
1. include the namespace in file
2. handle the idisposable objects inside using block.

iFace obj = new myclass()

Myclass obj1 = new myclass()

Obj.hey();
Obj1.hey();

is the above code is valid?
yes

Question. What is difference between lock vs static locks?
Answer. static lock is applicable to static methods and variables.

Question. What is suppressfinalize?
Answer. We use this method to not to call the finalize method while disposing the objects.

Question. Can we inherit a class from multiple interfaces?
Answer. yes

Question. suppose two interfaces have same method, so how will you implement these methods in derive class?
Answer. by using interface name

Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution

c# dotnet interview Questions

c# dotnet interview Questions
Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution

Question. What collection type you used?
Answer. ArrayList

Question. What is difference between arraylist and array?
Answer. Array can store single data type and inserting will cost more, while in array list you can store multiple datatypes and inserting and removing element is easy.

Question. What are delegates?
Answer. it is function to pointer.

Question. What are events?
Answer. events are used with delegate to fire a method on any event occurrence?

Question. What is use of delegate?
Answer. Used of delegate to call a function.

Question. any other use of delegate?
Answer. Find out.

Question. What is difference between list and arraylist.
Answer. list is interface while arraylist is implementation.

Question. What is dataset?
Answer. can contains tables and their relations.

Question. What is datareader?
Answer. Read one row at a time , forward only.

Question. How will you fill dropdown values using datareader?
Answer.
While(datareader.read())
{
bind every value to dropdown
}

or construct a dataset from datareader inside loop and assign to dropdown

Question. What is abstraction?
Answer. Representing complex word in simplified manner.

Question. what is OOPs ?
Answer. programming language fully supported by objects

Question. What is Objects?
Answer. by using Objects we can represent real word easily.

Question. what are the features of objects oriented programming?
encapsulation
overloading
overriding
abstraction
association
generalization
inheritance
data hiding

Question. Have you worked on multithreaded application?
Answer. yes

Question. Describe the multithreaded application ?
Answer. Describe a demo multithread application and why using multithreading.

Question. What is Strongly typed dataset?
Answer. Strongly typed dataset is simple dataset containing the property to have datatype associated with columns and can access column values by using the column names.

Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution

Royal bank scotland telephonic Interview dotnet

Royal bank scotland Telephonic Interview dotnet

Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution

Question. Tell me something about yourself?

Answer. Give a small introduction about professional background.

Question. Tell me about current project and technology used?

Answer. As per your current project.

Question. Rate your self for .NET, C#, Oracle?
Answer.
.NET - 7
C# - 8
Oracle - 7

Question. Lets start with .NET, What is .NET framework?
Answer. Its a platform to run .NET application, where .net applications can use .net resources.

Question. What is DLL?
Answer. Dynamic link libraries, kind of exe file.

Question. What is manifest?
Answer. Contains Details about assembly. like reference, versions, resources and type.

Question. What types of assemblies are there and what is difference?
Answer. Private and public
private is private to application and kept in local application folder
public assemblies are shared among the applications and kept in GAC.

Question. Suppose there is two versions of a assembly, how your application will decide which version to use?
Answer. In web.config under binding give old version and new version

Q. Any other way to do versioning in GAC?
Answer. Find it out.

Q. What is strong type and loose type ?
Answer. its a language property. The language who provide variable data type declaration called loose type like vb and JavaScript provide var type variable declaration while C# not. so C# is strong type language.

Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution

RBS C# dotnet interview questions

RBS C# dotnet interview questions
Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution

Question 1. What technologies you worked for?
Answer. C#, VB, Oracle , SQL Server , ASP.NET, JavaScript
Question 2. Lets start with C#, What is modularization?
Answer. Modularization is dividing functionality into different small modules, so that we can reuse the functionality and make it simple to use.
Question 3. Any other use of modularization and Layered application?
Answer. We can add layer to keep different group of functionalities different. and changing one layer does not effect others.
Question 4. Where does the object and its internal variable int i and string s store, in heap or in stack.
Answer. i think int goes to stack
Question 5. What is garbage collector?
Answer. it used to release the memory. and run in non deterministic manner.
Question 6 Can we run Garbage collector manually and its recommended?
Answer. Yes we can by gc.collect(), it is not recommended.
Question 7. What is overloading and overriding?
Answer. overriding is having same method in base and drive class and deciding at runtime which one to call.
Question 8. What is difference between the runtime polymorphism and overriding.
Answer. both are same.
Question 9. Difference between string builder and string?
Answer. string builder is mutable and string immutable.
Question 10. can we pass object with ref parameter like fun(ref Obj)?
Answer.yes
Question 11. what is difference between fun(obj) and fun(ref obj)?
Answer. by passing obj we are directly passing object while using ref it passes the address of object.
Question 12. if we have two function abc(int a, int b) and abc(int a, int b, int c) in base class and we derive it in drive class and implement it. in drive class it is overloading or overriding?
Answer. both overloading and overriding.
Question 13. can we have multiple try blocks, can we have multiple catch blocks, can we have multiple finally blocks?
Answer. multiple try yes separate blocks, multiple catch -yes, multiple finally - no
Question 14. What is cluster index and noncluster index ?
Answer.
cluster index is physical sorting on table while non cluster index is logical sorting on table.
Question 15. we have a query,
select a, b from table1
where a=a1 and b=b1 and c= c1
on what column will you define the index?
Answer. a, b
Question 16. we have a table empl
emp_id, salary, division
get the employee list whose salary is greater than the average salary of their division?
Answer.
Question 17. there is two tables
emp_id, salary, division_id - emp table
division_id , div_name - div table
get the maximum salary if every division?
Answer.
Question 18. What patterns you used in C# code?
Answer. Singleton, facade
Question 19. Write a code to implement a singleton pattern?
Answer.
Question 20. write a code to check balance brackets in a string? ((()))
Answer.
Please friends to contribute questions of company interviews you attended mail us cinterviews.blogspot.com@gmail.com it will be useful for our job search community.www.cinterviews.com appreciates your contribution
 
Top Blogs