-
C# में Jagged Arrays को Initialize कैसे करें?
Jagged Array, Arrays का Array होता है। आप int Type के marks नाम के Jagged Array को इस तरह Declare कर सकते हैं:int[][] marks;Jagged Array को इस तरह Initialize करें:int[][] marks = new int[2][]{new int[]{92,93,94},new int[]{85,66,87,88}};Marks दो Arrays of Integers का Array है।marks[0] 3 Integers का A
-
C# में Array में Elements को Initialize कैसे करें?
सभी Arrays Contiguous Memory Locations से Consist होते हैं। Lowest Address First Element से Correspond करता है और Highest Address Last Element से। Array को Initialize करने के लिए, पहले आपको इसे Declare करना होगा। int[] marks; यहां, int Datatype है [] Array के Size को Specify करता है Marks Array क
-
C# में Variables को Initialize कैसे करें?
Variable एक Name है जिसे Storage Area दिया जाता है जिसे हमारे Programs Manipulate कर सकते हैं।C# में प्रत्येक Variable का एक Specific Type होता है, जो Variable की Memory के Size और Layout, उस Memory में Store की जा सकने वाली Values की Range और Variable पर Apply किए जा सकने वाले Operations के Set को
-
C# में Assignment Operators क्या हैं?
Operator एक Symbol है जो Compiler को Specific Mathematical या Logical Manipulations Perform करने के लिए कहता है।C# में निम्न Assignment Operators हैं।OperatorDescriptionExample=Simple Assignment Operator, Right Side Operands से Values को Left Side Operand में Assign करता हैC = A + B, A + B की Value
-
C# में Abstract Classes क्या हैं?
Abstract Classes में Abstract Methods होते हैं, जिन्हें Derived Class द्वारा Implement किया जाता है। Derived Classes में अधिक Specialized Functionality होती है।निम्न C# में Abstract Classes के उपयोग को दर्शाने वाला एक Example है।Exampleusing System; namespace Demo { abstract class Shape
-
C#.NET में Access Specifiers क्या हैं?
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
-
C# में Abstract Properties क्या हैं?
Abstract Property Declaration द्वारा Property Accessors का Implementation Provide नहीं किया जाएगा।आइए देखते हैं कि Abstract Properties के साथ कैसे काम करें। यहां हमारे पास एक Abstract Class Shape है जिसके दो Derived Classes हैं: Square और Circle।यहां, हमारे पास एक Abstract Area Property है।निम्न Cir
-
C# में Public, Protected और Private Access Specifiers में क्या अंतर है?
Public Access SpecifierPublic Access Specifier एक Class को अपने Member Variables और Member Functions को अन्य Functions और Objects के लिए Expose करने की अनुमति देता है। किसी भी Public Member को Class के बाहर से Access किया जा सकता है।Exampleusing System; namespace Demo { class Rectangle
-
C# में Properties के Accessors क्या हैं?
Properties Fields का Extension हैं और इन्हें Same Syntax का उपयोग करके Access किया जाता है। ये Accessors का उपयोग करते हैं जिनके माध्यम से Private Fields के Values को Read, Write या Manipulate किया जा सकता है।Property का Accessor उन Executable Statements को Contain करता है जो Property को Get (Read य
-
C# Lists में Add, Remove Methods क्या हैं?
List<T> C# में एक Collection है और यह एक Generic Collection है। Add और Remove Methods का उपयोग C# Lists में Elements को Add और Remove करने के लिए किया जाता है।आइए देखते हैं कि C# में Add() Method का उपयोग कैसे करें।Exampleusing System; using System.Collections.Generic; class Program { &
-
C# में सभी संभावित Array Initialization Syntaxes क्या हैं?
C# में Array को एक से अधिक तरीकों से Initialize किया जा सकता है। आइए कुछ Examples देखते हैं।Method OneArray के Size का उपयोग करके।int[] marks = new int[5] { 99, 98, 92, 97, 95};Method TwoSize को Omit करके।int[] marks = new int[] { 99, 98, 92, 97, 95};Method ThreeDeclaration के समय Initialize करके।in
-
C# में ArrayList को Sort कैसे करें?
C# में ArrayList को Sort करने के लिए, Sort() Method का उपयोग करें।निम्न ArrayList है:ArrayList arr = new ArrayList(); arr.Add(32); arr.Add(12); arr.Add(55); arr.Add(8); arr.Add(13);अब ArrayList को Sort करने के लिए Sort() Method का उपयोग किया जाता है।arr.Sort();C# में ArrayList को Sort करने के लिए नि
-
C# में Regular Expressions में Anchors क्या हैं?
Anchors, C# में Regular Expressions में Constructs हैं। यह Current Position in the String के आधार पर Match को Succeed या Fail होने देता है। निम्न Table Anchors को List करती है। Assertion Description Pattern Matches ^ Match String या Line की Beginning पर Start होना चाहिए ^\d{3} 567 in 567-777-
-
C# में Anonymous Methods क्या हैं?
Anonymous Methods वे Methods होती हैं जिनका कोई Name नहीं होता। ये Methods एक Code Block को Delegate Parameter के रूप में Pass करने की Technique Provide करती हैं।Anonymous Methods, Delegate Instance के Creation के साथ, Delegate Keyword के साथ Declare की जाती हैं।Exampleusing System; delegate void De
-
C# में Arithmetic Operators क्या हैं?
Operator एक Symbol है जो Compiler को Specific Mathematical या Logical Manipulations Perform करने के लिए कहता है।OperatorDescriptionExample+दो Operands को Add करता हैA + B = 30-Second Operand को First से Subtract करता हैA - B = -10*दोनों Operands को Multiply करता हैA * B = 200/Numerator को De-numerat
-
C# में Attributes क्या हैं?
Attribute एक Declarative Tag है जिसका उपयोग आपके Program में Classes, Methods, Structures, Enumerators, Assemblies आदि जैसे विभिन्न Elements के Behaviors के बारे में Runtime को Information Convey करने के लिए किया जाता है। निम्न Syntax है। [attribute(positional_parameters, name_parameter = value, ..
-
C# में Base और Derived Classes क्या हैं?
एक Class को एक से अधिक Class या Interface से Derive किया जा सकता है, जिसका अर्थ है कि यह Multiple Base Classes या Interfaces से Data और Functions Inherit कर सकती है।उदाहरण के लिए, Vehicle Base Class निम्न Derived Classes के साथ:Truck Bus MotobikeDerived Class, Base Class के Member Variables और Membe
-
C# में Bitwise Operators क्या हैं?
Bitwise Operator Bits पर काम करता है और Bit-by-Bit Operation Perform करता है।निम्न Bitwise Operators हैं:OperatorDescriptionExample&Binary AND Operator Result में Bit को Copy करता है यदि वह दोनों Operands में Exist करता है।(A & B) = 12, जो 0000 1100 है|Binary OR Operator Bit को Copy करता है
-
C# में Boolean Types क्या हैं?
Boolean Type के लिए, bool Keyword का उपयोग किया जाता है और यह System.Boolean का Alias है।इसका उपयोग Boolean Values, True और False को Store करने के लिए Variables Declare करने के लिए किया जाता है।आइए एक Example देखते हैं कि C# में bool का उपयोग कैसे करें।Exampleusing System; public class Demo {
-
C# में Pre-Processor Directives क्या हैं?
Preprocessor Directives Compiler को Actual Compilation शुरू होने से पहले Information को Preprocess करने का Instruction देती हैं।सभी Preprocessor Directives # से शुरू होती हैं, और एक Line पर Preprocessor Directive से पहले केवल White-Space Characters दिखाई दे सकते हैं। Preprocessor Directives Statemen