What are the access allowed for compilation
units(namespace),class and structs and what are its default
access?



What are the access allowed for compilation units(namespace),class and structs and what are its def..

Answer / basavaraju.c

Namespace : It is not possible to use any access specifiers
like private, public etc with a namespace declarations. The
namespaces in C# are implicitly have public access and this is
not modifiable.

For Class and Structs we can only use internal and public.
(default access is Internal)

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Sharp Interview Questions

Difference between direct type casting and using "as" keyword?

1 Answers   TCS,


What is Lambda Expression?

1 Answers  


What is the difference between c and c sharp?

0 Answers  


What are the advantages of using partial classes?

0 Answers  


Why is it a bad idea to throw your own exceptions?

4 Answers  






What does string intern do?

0 Answers  


What is cshtml?

0 Answers  


Can you put two constructor with the same structure in a class?

0 Answers  


What namespaces are necessary to create a localized application?

2 Answers   Rolta, Siebel Systems, Visual Soft,


Explain about Oops concept

0 Answers   Digital GlobalSoft,


Why do we use lambda expression in c#?

0 Answers  


How did you implemented classes in your project?

1 Answers   TCS,


Categories