Abundant Code

  • C#
  • C++
  • Elastic Search
  • Entity Framework
  • F#
  • JavaScript
  • ASP.NET
  • C
  • Java
  • SQL Server
  • Assembly Lang
Home ยป operator

How to Find if the Number is a Power of 2 using Bitwise Operator in C# ?

May 27, 2014 by AbundantCode Leave a Comment

If you need to find out if the number is a Power of 2 using BitWise Operator in C# , below is a sample code snippet that demonstrates how to do it.

How to Find if the Number is a

…

Filed Under: C# Tagged With: Bitwise, C#, How to, operator, Power of 2

How to Use the Null Coalescing Operator (??) in C# ?

April 7, 2014 by AbundantCode Leave a Comment

There are times when you simply want to check if the value is null and perform some steps based on the condition . The Null Coalescing Operator (??) can help you achieve this.

How to Use the Null Coalescing Operator

…

Filed Under: C# Tagged With: ??, C#, How to, Null Coalescing, operator

Using Null Coalescing Operator in C#

December 26, 2013 by AbundantCode Leave a Comment

Sometimes , you may want to simply the Null checks in your .NET Program without much usage of the if statements .

The Null Coalescing Operator can be used in this scenario.

Using Null Coalescing Operator in C#

using System;
…

Filed Under: C# Tagged With: C#, Null Coalescing, operator, using

Using or Operator in the Where Clause of LINQ in C#

August 16, 2013 by AbundantCode Leave a Comment

Below is a sample code snippet demonstrating on how to use “Or” Operator in the Where Clause of Linq in C#?

Using or Operator in the Where Clause of LINQ in C#

using System;

using System.Collections.Generic;

using System.Data;

using System.Linq;

…

Filed Under: C# Tagged With: C#, Clause, LINQ, operator, using

How to use SQL like Operator in LINQ and C#?

July 26, 2013 by AbundantCode Leave a Comment

In a SQL Query, one might use the Like Query which can be used along with the % operator to search of contains within the data. How to use SQL like Operator in LINQ and C#? This article will show …

Filed Under: C# Tagged With: C#, How to, LINQ, operator, SQL like

The ? (ternary) Operator in C#

May 18, 2013 by AbundantCode Leave a Comment

The ? Operator is the ternary operator and takes the following form

Expression1? Expression2: Expression3;

The Expression1 is an expression which returns Boolean result. Expression2 is considered if the Expression1 is true else Expression2 is taken.…

Filed Under: C# Tagged With: C#, operator, ternary, tutorials

& and && in C#

May 13, 2013 by AbundantCode Leave a Comment

Below is a sample soucrecode demonstrating the usage of & and && operator in c#.

using System;

namespace AbundantCode

{

internal class Program

{

//& and && in C#

private static void Main(string[] args)

{

bool Input1 = true, input2 
…

Filed Under: C# Tagged With: &, &&, C#, operator

Postfix and Prefix Operator in C#

May 10, 2013 by AbundantCode Leave a Comment

Below is a sample code snippet demonstrating the Postfix and Prefix Operator in C#

using System;

namespace AbundantCode

{

internal class Program

{

//Arithmetic Operators in C#

private static void Main(string[] args)

{

int Input = 100;

Input = Input++;

…

Filed Under: C# Tagged With: C#, operator, tutorials

@ Operator in C#

August 18, 2012 by AbundantCode Leave a Comment

Although it is not the best practise , If you want use the reserve words and the variable name , you could use the @ prefixed before the variable name .

Below is a sample sourcecode that demonstrates the use …

Filed Under: C# Tagged With: @, C#, operator

RSS
Facebook
fb-share-icon
Twitter
Visit Us
Follow Me
Tweet

Recent Posts

  • InvalidModuleDescriptorException when running java program in Eclipse IDE
  • Python Program to Check Armstrong Number
  • Collapsible links for subcategories in Docusaurus Sidebar
  • Python Program to Print Fibonacci Series
  • Python Program to Generate Multiplication Table

Categories

Tags

.NET App Array ASP.NET ASP.NET MVC Assembly Language C# C# programs c lab programs Collection convert C program csharp database Example F# guide How to How to in Java integer Java Javascript Lab programs Lambda LINQ List Python lab programs Python programs SIC/XE SQL Server string tips tricks tutorial tutorials UWP visual studio 2015 Windows Windows 8 Windows 10 Windows Phone Windows Phone 8 Windows Phone 8.1 wp8 XAML

Blog Stats

  • 8,748,784 hits

Archives

Top Posts & Pages

  • How to Convert a Stream to Byte Array in C# 4.0 ?
  • How to open display settings from command line in Windows 10 ?
  • How to retrieve the URL of the current Page in ASP.NET MVC 4 Controller ?
  • C Program to Multiply Two Matrices Using Multi-dimensional Arrays
  • How to clean up unused PowerPoint master slides in PowerPoint?
  • How to Quickly Delete All Rows in a Table in Entity Framework?
  • C Program to display half-pyramid using alphabets
  • How to Allow only numeric input in a Textbox in WPF ?
  • System Software - SIC/XE Program to divide BETA by GAMMA and set quotient and remainder
  • How to Calculate MD5 checksum for a file in C# ?

Categories

  • Android
  • Angular 2
  • ASP.NET
  • Assembly Language
  • C
  • C#
  • C++
  • Elastic Search
  • Entity Framework
  • Excel
  • F#
  • HTML
  • Interview Questions
  • Java
  • JavaScript
  • jQuery
  • Microsoft Office
  • MySQL
  • NETWORK
  • News
  • PHP
  • popular
  • PowerShell
  • Python
  • Ruby
  • SharePoint
  • SQL Server
  • SQL Server
  • Unix
  • VB.NET
  • Visual Studio
  • WebAPI
  • Windows
  • Windows Azure
  • Windows Forms
  • XAML

Top Posts & Pages

  • How to Convert a Stream to Byte Array in C# 4.0 ?
  • How to open display settings from command line in Windows 10 ?
  • How to retrieve the URL of the current Page in ASP.NET MVC 4 Controller ?
  • C Program to Multiply Two Matrices Using Multi-dimensional Arrays
  • How to clean up unused PowerPoint master slides in PowerPoint?
  • How to Quickly Delete All Rows in a Table in Entity Framework?
  • C Program to display half-pyramid using alphabets
  • How to Allow only numeric input in a Textbox in WPF ?
  • System Software - SIC/XE Program to divide BETA by GAMMA and set quotient and remainder
  • How to Calculate MD5 checksum for a file in C# ?

Recent Posts

  • InvalidModuleDescriptorException when running java program in Eclipse IDE
  • Python Program to Check Armstrong Number
  • Collapsible links for subcategories in Docusaurus Sidebar
  • Python Program to Print Fibonacci Series
  • Python Program to Generate Multiplication Table
  • Python Program to Find the Factorial of a Number
  • Python Program to Print Prime Numbers in a Given Interval
  • Python Program to Check Prime Number
  • Python Program to Find the Largest Value Among Three Numbers
  • Python Program to Check If a Given Year is Leap Year

Tags

.NET App Array ASP.NET ASP.NET MVC Assembly Language C# C# programs c lab programs Collection convert C program csharp database Example F# guide How to How to in Java integer Java Javascript Lab programs Lambda LINQ List Python lab programs Python programs SIC/XE SQL Server string tips tricks tutorial tutorials UWP visual studio 2015 Windows Windows 8 Windows 10 Windows Phone Windows Phone 8 Windows Phone 8.1 wp8 XAML