Computer >> कंप्यूटर ट्यूटोरियल >  >> प्रोग्रामिंग >> C#

C#

  1. C# में Check करें अगर String के दोनों Halves में Same Characters हैं

    सबसे पहले, Check की जाने वाली String Set करें।string s = timetime;अब String के दो Halves के लिए दो Counters Set करें।int[] one = new int[MAX_CHAR]; int[] two = new int[MAX_CHAR];String के दोनों Halves Check करें।for (int i = 0, j = l - 1; i < j; i++, j--) {    one[str[i] - a]++;   &nb

  2. C# में char vs string Keywords

    string Keyword String Variable Declare करने के लिए string Keyword का उपयोग करें। string Keyword, System.String Class का Alias है। उदाहरण के लिए। string name; name = Tom Hanks; एक और Example। string[] array = { Hello, From, Tutorials, Point }; char Keyword char Keyword का उपयोग Characters के Arra

  3. C# में Enum Members Compare करना

    Enum Members Compare करने के लिए, Enum.CompareTo() Method का उपयोग करें।सबसे पहले, Students के लिए Values Set करें।enum StudentRank { Tom = 3, Henry = 2, Amit = 1 };अब CompareTo() Method का उपयोग करके एक Enum Value को दूसरे से Compare करें। 0 ? Yes : No, Environment.NewLine);निम्न Code C# में Enum M

  4. C# में 'is' Operator का Purpose क्या है?

    C# में is Operator Check करता है कि Object का Run-Time Type दिए गए Type के साथ Compatible है या नहीं।निम्न Syntax है।expr is typeयहां, expr Expression हैtype Type का Name हैनिम्न Example C# में is Operator के उपयोग को दर्शाता है।Exampleusing System; class One { } class Two { } public class Demo { &n

  5. C# में Access Specifier का Purpose क्या है?

    Class Member के Scope और Visibility को Define करने के लिए, Access Specifier का उपयोग करें। C# निम्न Access Specifiers Support करता है। Public Private Protected Internal Protected Internal आइए इन्हें एक-एक करके सीखते हैं। Public Access Specifier यह एक Class को अपने Member Variables और Member Functi

  6. C# में Power-of-2-Number द्वारा Modulus Division Compute करें

    हमने Number को निम्न रूप में लिया है:uint a = 9; uint b = 8;ऊपर, a Divisor है और b Dividend है।Modulus Division Compute करने के लिए।Exampleusing System; class Demo {    static uint display(uint a, uint b) {       return (a & (b - 1));    }    static publi

  7. C# में Files Compress और Decompress करना

    C# में Files Compress और Decompress करने के लिए System.IO.Compression Namespace का उपयोग करें।CompressFile Zip करने के लिए, FileStream Class के साथ GZipStream Class का उपयोग करें। निम्न Parameters Set करें: Zip की जाने वाली File और Output Zip File का Name।यहां, OutputFile Output File है और File को F

  8. C# में Const vs Static vs Readonly

    ConstConstant Fields वे Fields हैं जिन्हें Modified नहीं किया जा सकता। Declaration के समय, आपको इसमें Value Assign करनी होगी।const int a = 5;Staticयदि Static Modifier Class पर Apply किया जाता है तो आप New Keyword का उपयोग करके Class को Instantiate नहीं कर सकते। Methods, Properties, Classes, Construc

  9. C# में DivideByZeroException Class

    C# Exceptions को Classes द्वारा Represent किया जाता है। C# में Exception Classes मुख्य रूप से Directly या Indirectly System.Exception Class से Derived होती हैं। System.Exception Class से Derived कुछ Exception Classes हैं System.ApplicationException और System.SystemException Classes।System.DivideByZe

  10. C# में Method को Asynchronously Call करें

    C# में Asynchronous Programming, Blocked Activities या Delayed Access के प्रति Efficient Approach है। यदि कोई Activity इस तरह Blocked होती है एक Synchronous Process में, तो Complete Application Wait करता है और इसमें अधिक Time लगता है। Application Respond करना बंद कर देती है। Asynchronous Approach का

  11. C# में Dynamic Binding

    Dynamic Binding में, Compiler Compile Time पर Type Checking नहीं करेगा। Run Time पर Checking की जाती है।Anonymous Types को One Method तक Restrict करने से बचने के लिए इसका उपयोग करें। ऐसा केवल इसलिए क्योंकि Type Name केवल Compiler को Visible होता है; इसलिए, आप इसे Method के Return Value के रूप में De

  12. C# में SortedList Class की Keys Property क्या है?

    SortedList में Keys को SortedList Class की Keys Property का उपयोग करके Get करें। हमने पहले SortedList Property को Elements के साथ Set किया है।SortedList sl = new SortedList(); sl.Add(ST0, One); sl.Add(ST1, Two); sl.Add(ST2, Three); sl.Add(ST3, Four); sl.Add(ST4, Five); sl.Add(ST5, Six); sl.Add(ST6,

  13. C# में Task Start करने के Different Ways

    C# में Task Start करने के लिए, नीचे दिए गए किसी भी तरीके को Follow करें। Task Start करने के लिए Delegate का उपयोग करें। Task t = new Task(delegate { PrintMessage(); }); t.Start(); Task Start करने के लिए Task Factory का उपयोग करें। {Console.WriteLine(Welcome!); }); Lambda का भी उपयोग कर सकते हैं।

  14. C# में Exception Propagation

    Exception Propagation को C# में Exception Handling कैसे काम करता है, उससे समझा जा सकता है।Try में, जब Exception Occur होता है तो Corresponding Catch Blocks Check किए जाते हैं। यह यह देखने के लिए किया जाता है कि क्या वे Exception Catch कर सकते हैं। यदि कोई Matching Exception नहीं मिलता, तो Exception

  15. C# में Dictionary Methods

    Dictionary C# में Keys और Values का Collection है। Dictionary<TKey, TValue> System.Collection.Generics Namespace में शामिल है।निम्न Methods हैं:Sr.NoMethod & Description1AddDictionary में Key-Value Pairs Add करता है2Clear()सभी Keys और Values Remove करता है3RemoveSpecified Key वाले Element

  16. C# का उपयोग करके Headnode से Nth Element Delete करें

    सबसे पहले, एक Linked List Set करें और कुछ Elements Add करें।Demo list = new Demo(); list.Push(50); list.Push(100); list.Push(150);अब Headnode से Nth Element Delete करने के लिए, वह Pass करें जिसे आप Delete करना चाहते हैं। यदि आप 1 Set करेंगे, तो यह Head Node Delete करेगा।Exampleif (val == 1) {  

  17. C# में Debug Class vs Debugger Class

    अपने Code को Debug करने के लिए, आपको Methods या Properties की आवश्यकता होती है, जो C# में Debug Class द्वारा Provide की जाती हैं। Debugger Class का उपयोग Debugger के साथ Communication Set करने के लिए किया जाता है। Debug Class Debug Class System.Diagnostics से Inherit करती है। Syntax है: public stat

  18. C# में Dependency Injection

    C# में Dependency Injection का Concept Loosely Coupled Code के Development को Enable करने के लिए Introduced किया गया था। Loosely Coupled Code को Easily Maintained और Reused किया जा सकता है। C# में Dependency Injection के निम्न Types हैं। Constructor Injection Dependencies Inject करने के लिए, Constru

  19. C# Regular Expression में Quantifiers समझाया गया

    C# में Quantifiers Specify करते हैं कि Previous Element (जो Character, Group, या Character Class हो सकता है) के कितने Instances Input String में Present होने चाहिए Match के लिए। Quantifier Description Pattern Matches * Previous Element को Zero या More Times Match करता है। \d*\.\d .0, 19.9, 219.9

  20. C# में Var और Dynamics में अंतर

    C# में Var Strictly Typed है, जबकि Dynamic Strictly Typed नहीं है। Var Declaration var a = 10; Dynamic Declaration dynamic a = 10; Var एक Implicitly Typed Variable है, लेकिन यह Compile Time Errors को Bypass नहीं करेगा। C# में Var का Example var a = 10; a = Demo; // Compile Error देता है C# में

Total 2668 -कंप्यूटर  FirstPage PreviousPage NextPage LastPage CurrentPage:70/134  20-कंप्यूटर/Page Goto:1 64 65 66 67 68 69 70 71 72 73 74 75 76