delphi及c#語法比較

delphi及c#語法比較

ID:8392266

大?。?39.00 KB

頁數(shù):13頁

時(shí)間:2018-03-25

delphi及c#語法比較_第1頁
delphi及c#語法比較_第2頁
delphi及c#語法比較_第3頁
delphi及c#語法比較_第4頁
delphi及c#語法比較_第5頁
資源描述:

《delphi及c#語法比較》由會(huì)員上傳分享,免費(fèi)在線閱讀,更多相關(guān)內(nèi)容在學(xué)術(shù)論文-天天文庫。

1、窗體頂端窗體底端您查詢的關(guān)鍵詞是:delphi?c#?。如果打開速度慢,可以嘗試快速版;如果想保存快照,可以添加到搜藏。(百度和網(wǎng)頁http://www.360doc.com/content/070405/11/2908_431505.html的作者無關(guān),不對其內(nèi)容負(fù)責(zé)。百度快照謹(jǐn)為網(wǎng)絡(luò)故障時(shí)之索引,不代表被搜索網(wǎng)站的即時(shí)頁面。)幫助?

2、?留言交流?

3、?首頁我的圖書館主題閱讀精彩目錄精品文苑Tags會(huì)員瀏覽好書推薦DELPHI與C#語法比較(轉(zhuǎn)載)kenwang收錄于2007-04-05閱讀數(shù):公眾公開?原文來源 DELPHIandC#ComparisonDELPHI7與C#語法比較編制

4、:黃煥堯參考:VB.netandC#Comparison日期:2005-5-30.Comments注釋DataTypes數(shù)據(jù)類Constants常量Enumerations枚舉Operators運(yùn)算Choices選擇語句Loops循環(huán)語句Arrays數(shù)組Functions函數(shù)ExceptionHandling異常處理Namespaces命名空間Classes/InterfacesConstructors/Destructors構(gòu)造/釋構(gòu)Objects對象Structs結(jié)構(gòu)Properties屬性Delegates/EventsConsoleI/OFileI/ODELPHIC#Commen

5、ts注釋//Singlelineonly{?Multipleline}(*?Multipleline*)//Singleline/*Multiple???line?*////XMLcommentsonsingleline/**XMLcommentsonmultiplelines*/DataTypes數(shù)據(jù)類型ValueTypes簡單類型BooleanByteChar??(example:"A"c)Word,Integer,Int64Real,Single,Double,Real48,Extended,Comp,CurrencyDecimalTdate,TDateTimeReferenceT

6、ypesObjectString(ShortString,AnsiString,WideString)Set,array,record,file,class,classreference,interfacepointer,procedural,variantvarx:Integer;WriteLine(x);????//?PrintsSystem.Int32WriteLine('Ingeger’);?//PrintsInteger//?TypeconversionvarnumDecimal:Single=3.5;varnumInt:Integer;numInt:=Integer(numD

7、ecimal)??//setto4(Banker'srounding)thedecimal)ValueTypesboolbyte,sbytechar??(example:'A')short,ushort,int,uint,long,ulongfloat,?doubledecimalDateTime??(notabuilt-inC#?type)ReferenceTypesobjectstringintx;Console.WriteLine(x.GetType());????//PrintsSystem.Int32Console.WriteLine(typeof(int));?????//P

8、rintsSystem.Int32//TypeconversiondoublenumDecimal=3.5;intnumInt=(int)numDecimal;??//setto?3?(truncatesdecimal)Constants常量Const?MAX_STUDENTS:Integer=25;constintMAX_STUDENTS=25;Enumerations枚舉TypeTaction1=(Start,Stop,Rewind,Forward);{$M+}TypeStatus=(Flunk=50,Pass=70,Excel=90);enumAction{Start,Stop,R

9、ewind,Forward};enumStatus{Flunk=50,Pass=70,Excel=90};Actiona={$M-}vara:Taction1=Stop;Ifa<>StartThenWriteLn(ord(a));???//Prints?1WriteLine(Ord(Pass));????//Prints70WriteLine(GetEnumName(TypeInfo(Status),Ord(Pass)));???/

當(dāng)前文檔最多預(yù)覽五頁,下載文檔查看全文

此文檔下載收益歸作者所有

當(dāng)前文檔最多預(yù)覽五頁,下載文檔查看全文
溫馨提示:
1. 部分包含數(shù)學(xué)公式或PPT動(dòng)畫的文件,查看預(yù)覽時(shí)可能會(huì)顯示錯(cuò)亂或異常,文件下載后無此問題,請放心下載。
2. 本文檔由用戶上傳,版權(quán)歸屬用戶,天天文庫負(fù)責(zé)整理代發(fā)布。如果您對本文檔版權(quán)有爭議請及時(shí)聯(lián)系客服。
3. 下載前請仔細(xì)閱讀文檔內(nèi)容,確認(rèn)文檔內(nèi)容符合您的需求后進(jìn)行下載,若出現(xiàn)內(nèi)容與標(biāo)題不符可向本站投訴處理。
4. 下載文檔時(shí)可能由于網(wǎng)絡(luò)波動(dòng)等原因無法下載或下載錯(cuò)誤,付費(fèi)完成后未能成功下載的用戶請聯(lián)系客服處理。