C# 學習筆記 part 6 創建 class 物件,使用 class 物件

C# 入門 教學 6 創建 class 物件,使用 class 物件

哇...一下跳到 class 物件,別驚訝,程式有簡單,有困難...

很多教學,都是從基礎...開始講...雖然很重要...

但...等說到 class 物件時,大概就掛了、嗝屁、翹辮子、翻白肚...

所以,開始就用 class 物件,然後範例,儘量使用 class 物件...

如果你未安裝 Visual Studio 開發套件,參考 C# 學習,教你下載安裝 Visual Studio Community

卡在命名問題,參考 C# 學習 part 3 卡在第一關,命名問題...只能借助 Goole 翻譯

回顧上一篇,參考 C# 學習,變數交換,將變數 a 的值,與變數 b 值,做交換


步驟












代碼






執行結果







認識一下,代碼內的專有名詞

訪問權限




那個 $ 字串插補,參考

https://docs.microsoft.com/zh-tw/dotnet/csharp/language-reference/tokens/interpolated




必須知道,幫助快鍵 F1




將滑鼠指標,移到不懂,要查的 ( 關鍵字 ) 上面,按下 F1 快鍵




就可以,打開線上 MSDN 查看該 ( 關鍵字 ) 是幹什麼用的,相當方便




C# 學習筆記,了解創建 class 物件,那串代碼,是什麼意思




此篇文章之圖文教學,如果還不太明白,請至下方連結,查看 youtube 視頻解說

視頻解說之第一部分 https://www.youtube.com/watch?v=0IX8BBn5nR4

謝謝大家,抽空觀看,files備份檔名 csharp00006


後續文章 C# part 7 創建 Windows Forms 視窗應用程式,使用 Windows Forms 視窗應用程式


C# tutorial 6 Show you how to create a new class and use

沒有留言:

發佈留言

由於一直被灌水, 因此您發表留言之後, 需要等待博客主的審核, 才會公開您的留言, 所以請不要重複的留言
Hello my friend, I have no money, My blog is super chill, Please do not screw me up in the replies at the bottom of the article, thanks a lot