C#英文面試常見問題[轉]

来源:http://www.cnblogs.com/czytcn/archive/2017/12/21/8080336.html
-Advertisement-
Play Games

I was reading a post about some common C# interview questions, and thought I’d share some of mine. These are questions that I asked in interviews, or ... ...


I was reading a post about some common C# interview questions, and thought I’d share some of mine. These are questions that I asked in interviews, or was asked in past interviews. Try them out and see you how you do! I’m not going to post the answers here, if you don’t know them, find out!

Common C# (and .Net) Interview Questions
  • What are the different types of collections in .Net?
  • What are the benefits offered by generics as opposed to other collections?
  • What is the difference between a class and a struct?
  • When calling a function, are parameters passed by value or by reference?
  • What are the different ways to pass a parameter by reference?
  • What are the mechanisms for maintaining state in an asp.net application?
  • Describe inheritance. Describe different ways you can implement inheritance.
  • What is dependency injection?
  • How do you override a static method?
  • Name some of the parts of the page life cycle in ASP.NET.
  • Where I would validate something like an email address?
  • What is the difference between public, static and void?
  • What are Jagged Arrays?
  • What is serialization?
  • Can “this” be used within a static method?
  • What is the difference between Array and Arraylist?
  • Can a private virtual method be overridden?
  • Describe the accessibility modifier “protected internal”.
  • What are the differences between System.String and System.Text.StringBuilder?
  • What’s the difference between the System.Array.CopyTo() and System.Array.Clone()?
  • What’s the difference between an interface and abstract class?
  • What is the difference between Finalize() and Dispose() methods?
  • What’s an object pool?
  • What is the difference between method overriding and method overloading?
  • What is the difference between a Struct and a Class?
  • What are Indexers?
MS SQL
  • What are the different ways for storing behaviors in SQL?
  • What are the different kinds of SQL joins? When would you use each?
  • If you have a slow running query that looks at seldom changed data, how might you speed it up?
  • Describe the different types of joins?
  • What is the no-lock feature?
  • How do you make sure you maintain your referential integrity?
  • He asked me to describe the Controller?
  • What is a clustering index?
  • How do you handle an error in a SQL query?
Exercises
  • Name the 3 language features that make a programming language object-oriented.
  • Write a C# method that takes an array of integers and returns the largest integer in the array
  • Explain the difference between pass by value and pass by reference?
  • Write a C# method that will reverse a string (e.g. “abcd” -> “dcba”). Make sure that it works.
  • Write a function that tests if a string is a Palindrome
  • Write this same function recursively
  • Write a function that acts as a telegraph, that has a set limit of characters per line (for example only 20 characters per line) and break it up so you don’t split any words.
Summary

These are just a few I had stored over the years for interviews, but I’ll come up with some more. It’s always good to keep brushed up on this stuff to make sure your skill level is where you think it should be.


轉自 https://www.jeremymorgan.com/blog/programming/c-sharp-interview-questions/


您的分享是我們最大的動力!

-Advertisement-
Play Games
更多相關文章
  • 小知識點總結 一、Python2與Python3 的區別 1、Python2中可以加括弧輸出,也可不加輸出 Python3中必須加 2、python2 中有xrange(生成器)也有range python3中只有range 3、python2中的input為raw_input python3 中為 ...
  • 其實是:jsonmappingexception:no serializer found for class 由於後臺錯誤堆棧列印很快,只看到illegalStateException:stream 需要細心調試debug. 原因:與response 的geOutputStream out.getW ...
  • 很長一段時間以來,我都在思考如何在ASP.NET Core的框架下,實現一套完整的事件驅動型架構。這個問題看上去有點大,其實主要目標是為了實現一個基於ASP.NET Core的微服務,它能夠非常簡單地訂閱來自於某個渠道的事件消息,並對接收到的消息進行處理,於此同時,它還能夠向該渠道發送事件消息,以便... ...
  • 語句是過程式編程語言的基礎構造,對應於程式命令,通常按照指定順序執行。S#語句與C#語句基本相同,如有var, eval, if, switch, for, foreach, do, while, return, continue, break, load, using等語句。C/C++/Java/... ...
  • 一Socket介紹: 網路上的兩個程式通過一個雙向的通信連接實現數據的交換,這個連接的一端稱為一個socket。 建立網路通信連接至少要一對埠號(socket)。socket本質是編程介面(API),對TCP/IP的封裝,TCP/IP也要提供可供程式員做網路開發所用的介面,這就是Socket編程接 ...
  • using System; using System.Collections.Generic; using System.Linq; using System.Runtime.Remoting.Messaging; using System.Text; using System.Threading;... ...
  • 三層架構,我們一般說的三層架構通常指的是:1、表現層(UI):就是展現給用戶的界面,無論是網站前臺還是應用程式界面;2、業務邏輯層(BLL):針對具體問題的邏輯操作;3、數據訪問層(DAL):對數據進行操作。其他的層級基本都是在這三層之上的補充。 UI(User Interface)表示層: 就是我 ...
  • 本示例學習如何閱讀有多個await方法方法時,程式的實際流程是怎麼樣的,理解await的非同步調用 。 ...
一周排行
    -Advertisement-
    Play Games
  • 前言 本文介紹一款使用 C# 與 WPF 開發的音頻播放器,其界面簡潔大方,操作體驗流暢。該播放器支持多種音頻格式(如 MP4、WMA、OGG、FLAC 等),並具備標記、實時歌詞顯示等功能。 另外,還支持換膚及多語言(中英文)切換。核心音頻處理採用 FFmpeg 組件,獲得了廣泛認可,目前 Git ...
  • OAuth2.0授權驗證-gitee授權碼模式 本文主要介紹如何筆者自己是如何使用gitee提供的OAuth2.0協議完成授權驗證並登錄到自己的系統,完整模式如圖 1、創建應用 打開gitee個人中心->第三方應用->創建應用 創建應用後在我的應用界面,查看已創建應用的Client ID和Clien ...
  • 解決了這個問題:《winForm下,fastReport.net 從.net framework 升級到.net5遇到的錯誤“Operation is not supported on this platform.”》 本文內容轉載自:https://www.fcnsoft.com/Home/Sho ...
  • 國內文章 WPF 從裸 Win 32 的 WM_Pointer 消息獲取觸摸點繪製筆跡 https://www.cnblogs.com/lindexi/p/18390983 本文將告訴大家如何在 WPF 裡面,接收裸 Win 32 的 WM_Pointer 消息,從消息裡面獲取觸摸點信息,使用觸摸點 ...
  • 前言 給大家推薦一個專為新零售快消行業打造了一套高效的進銷存管理系統。 系統不僅具備強大的庫存管理功能,還集成了高性能的輕量級 POS 解決方案,確保頁面載入速度極快,提供良好的用戶體驗。 項目介紹 Dorisoy.POS 是一款基於 .NET 7 和 Angular 4 開發的新零售快消進銷存管理 ...
  • ABP CLI常用的代碼分享 一、確保環境配置正確 安裝.NET CLI: ABP CLI是基於.NET Core或.NET 5/6/7等更高版本構建的,因此首先需要在你的開發環境中安裝.NET CLI。這可以通過訪問Microsoft官網下載並安裝相應版本的.NET SDK來實現。 安裝ABP ...
  • 問題 問題是這樣的:第三方的webapi,需要先調用登陸介面獲取Cookie,訪問其它介面時攜帶Cookie信息。 但使用HttpClient類調用登陸介面,返回的Headers中沒有找到Cookie信息。 分析 首先,使用Postman測試該登陸介面,正常返回Cookie信息,說明是HttpCli ...
  • 國內文章 關於.NET在中國為什麼工資低的分析 https://www.cnblogs.com/thinkingmore/p/18406244 .NET在中國開發者的薪資偏低,主要因市場需求、技術棧選擇和企業文化等因素所致。歷史上,.NET曾因微軟的閉源策略發展受限,儘管後來推出了跨平臺的.NET ...
  • 在WPF開發應用中,動畫不僅可以引起用戶的註意與興趣,而且還使軟體更加便於使用。前面幾篇文章講解了畫筆(Brush),形狀(Shape),幾何圖形(Geometry),變換(Transform)等相關內容,今天繼續講解動畫相關內容和知識點,僅供學習分享使用,如有不足之處,還請指正。 ...
  • 什麼是委托? 委托可以說是把一個方法代入另一個方法執行,相當於指向函數的指針;事件就相當於保存委托的數組; 1.實例化委托的方式: 方式1:通過new創建實例: public delegate void ShowDelegate(); 或者 public delegate string ShowDe ...