Found 2587 Articles for Csharp

Difference between JavaScript and C#

Pradeep Kumar
Updated on 19-Apr-2023 17:31:58

650 Views

Two programming languages that have been widely used in the field of software development are JavaScript and C# (pronounce "C sharp"). Both languages are employed for various purposes and each has its own advantages and disadvantages. The main application of the programming language JavaScript is the creation of websites. It is frequently used to build dynamic and interactive web sites. Because JavaScript is a client-side language, it executes in the client's browser rather than on the server. It is a popular option for novices because it is simple to learn and has a low entry barrier. On the ... Read More

C# Program to Append Text to an Existing File

Ankit kumar
Updated on 14-Jul-2023 17:33:51

11K+ Views

Introduction Append means adding information to the already written document. Here, we will be learning to write a C# program to append text to an existing file. As we know file handling is done in C#. In most cases, the file is used to store data. File handling or file management in layman’s terms the various processes such as making the file, reading from it, writing to it, appending it, and so on. Only to Existing Files? Well, as we know appending generally means adding a piece of information to the already written document. But what if the file we ... Read More

C# Program to Generate Random Even Numbers Using LINQ Parallel Query

Ankit kumar
Updated on 04-Apr-2023 16:14:46

914 Views

Introduction In this article we will learn how to write a C# program that uses LINQ parallel query to generate random even numbers. Let's quickly review the language. The C# programming language is basically used to create desktop, internet, and mobile apps. Linguistic Integrated Query, also known as LINQ, is one of the advantages of C#. Developers may quickly access data from a variety of sources, including arrays, collections, and databases. Regardless of the data source, it offers a standard syntax for data queries. As LINQ and SQL share a similar syntax, developers can use and understand them both easily. ... Read More

C# Program to Generate Odd Numbers in Parallel using LINQ

Ankit kumar
Updated on 31-Mar-2023 15:16:16

497 Views

Introduction This article will teach you how to create a C# program that uses LINQ to generate odd numbers in parallel. Let's take a quick look at the language. The creation of desktop, online, and mobile apps generally uses the C# programming language. One of the strengths of C# is Linguistic Integrated Query, or LINQ. Data from many sources, including arrays, collections, and databases, can be rapidly accessed by developers. It provides a common syntax for data queries, regardless of the data source. As the syntax of LINQ and SQL is similar, developers can quickly understand and use them. ... Read More

C# Program to Find the Negative Double Numbers From the List of Objects Using LINQ

Ankit kumar
Updated on 31-Mar-2023 15:09:37

509 Views

Introduction In this article, we will learn how to write a C# program to find the negative double numbers from the list of objects using LINQ. Let's have a small overview of the language. The C# programming language is frequently used to develop desktop, web, and mobile apps. Working with big volumes of data can be difficult in any programming language. Finding data points that satisfy a certain set of requirements or filtering out specific values is a frequent activity when working with data. The Linguistic Integrated Query (LINQ) feature of C# can be utilised to simplify and improve ... Read More

C# Program to Find the List of Students whose Name Starts with ‘S’ using where() Method of List Collection using LINQ

Ankit kumar
Updated on 31-Mar-2023 15:07:55

478 Views

Introduction The topic to learn in this article is writing a C# Program to Find the List of Students whose Name Starts with 'S' using the where() Method of List Collection using LINQ. Language Integrated Query aka LINQ is used to generate queries in C# language. Previously we had to use other relational languages like SQL and XML. It provides more power to the C# language or any other .NET language. The syntax used to query the database in LINQ is the same as that of querying for data stored in an array. Before we proceed further and ... Read More

C# Program to estimate the size of the file using LINQ

Ankit kumar
Updated on 31-Mar-2023 16:54:59

243 Views

Introduction Let us try to understand the C# program to estimate the size of the file using LINQ. We will be understanding the LINQ (Language Integrated Query) and its methods and classes and how with their help, we will get the desired output. Language Integrated Query aka LINQ is used to generate queries in C# language. Previously we had to use other relational languages like SQL and XML. It provides more power to the C# language or any other .NET language. The syntax used to query the database in LINQ is the same as that of querying for data ... Read More

C# Program to Create File and Write to the File

Ankit kumar
Updated on 31-Mar-2023 16:53:22

8K+ Views

Introduction Creating a file and writing in it is the basics of file handling. Here, we are going to discuss a way to write a C# program to create the file and write to the file. File handling or file management in layman's terms the various processes such as making the file, reading from it, writing to it, appending it, and so on. The viewing and writing of files are the two most common operations in file management. Input and output happen due to the streams which provide a generic view of a sequence of bytes. Stream is an ... Read More

How to store/update Hashtable Elements?

Shilpa Nadkarni
Updated on 06-Jan-2023 15:14:33

2K+ Views

A hashtable is a data structure that consists of a collection of key-value pairs. The hashtable collection uses a hash function to compute the hash code of the key. A hashtable can also be defined as a non-generic collection of key-value pairs. The hash code of each key is computed using a hash function and is stored in a different bucket internally. At the time of accessing values, this hash code is matched with that of the specified key, and results are returned. Unlike other data structures like the stack, queue, ArrayList, etc. that store single values, hashtable collection stores ... Read More

How to Get Hashtable Elements as Sorted Array?

Shilpa Nadkarni
Updated on 06-Jan-2023 14:54:08

2K+ Views

A Hashtable is a non-generic collection of key-value pairs that are arranged as per the hash code of the key. A Hashtable is used to create a collection that uses a hash table for storage. The hashtable optimizes the lookup by calculating the hash code of each key and stores it internally into a basket. When we access the particular value from the hashtable, this hashcode is matched with the specified key. This hashtable collection is defined in the System.Collections namespace of C#. The class that represents the hashtable collection is the “Hashtable” class. This class provides constructors, methods, and ... Read More

Advertisements