Asp.net interview + test questions page 1/2

Source: Internet
Author: User

A beginner asp.net programmer should have the following knowledge:
(1) familiar with the Enterprise Manager, query analyzer, and event probe in SQL Server, proficient in writing T-SQL, stored procedures, user-defined functions, views, and triggers;
(2) understand the lifecycle of the ASP.net server control;
(3) familiar with HTML, CSS, javascript, xml, Web Service, and AJAX;
(4) master the multi-layer structure and class design methods;
(5) Understand website security vulnerability-related aspects and optimization skills;

1. Can I use Abstract Functions to override virtual functions in the base class?
A: Yes. The new modifier must be explicitly declared to hide the implementation of the function in the base class.
Copy codeThe Code is as follows:
Class BaseClass
{
Public virtual void ()
{
HttpContext. Current. Response. Write ("A Hui Nan ");
}
}

Abstract class dClass: BaseClass
{
Public new abstract void ();
}

2. What members can an interface contain?
A: An interface can contain attributes, methods, index indicators, and events, but cannot contain constants, fields, operators, constructors, and destructor.
And cannot contain any static members.

3. Copy an array to arrayList.
Copy codeThe Code is as follows:
String [] arrA = new string [] {"A", "yes", "Nan "};
ArrayList arrB = new ArrayList ();
Foreach (string a in arrA)
{
ArrB. Add ();
}
Foreach (string B in arrB)
{
Response. Write (B );
}

4. An overview of the three-tier architecture.
A: It mainly includes the interface layer, business logic layer, and data access layer.

5. Differences between StringBuilder and String.
A: When using the String class, a new object will be generated during the value assignment, but the StringBuilder will not. Therefore, in a large number of String concatenation or frequency
It is best to use StringBuilder to operate a string.

6. What is a virtual function? What is an abstract function?
A:
Virtual function: a function that is not implemented and can be inherited and overwritten by sub-classes.
Abstract function: Specifies a function that must be implemented by a non-virtual subclass and must be overwritten.

7. What is Web Service?
A: A Web Service is a network-based, distributed modular component that executes specific tasks and complies with specific technical specifications.
The specification enables the Web Service to interoperate with other compatible components.

8. What are common ADO.net objects?
A:
Connection: database Connection object
Command: Database Command
DataReader: data reader
DataSet: DataSet

9. What is the keyword of the delegate statement?
A: delegate

10. All Custom User Controls in ASP.net must inherit from?
Answer: Control class

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.