RSA encryption/decryption C# example

There are two classes for asymmetric encryption in .net. RSACryptoServiceProvider and DSACryptoserviceProvider . With the default constructor, both classes automatically create the public and private keys necessary to encryption…

How to randomize (shuffle) a JavaScript array?

In this article, I will show you how to shuffle an array in javascript. We will use The modern version of the Fisher-Yates shuffle, designed for computer use, was introduced by Richard Durstenfeld in 1964 The algorithm for shu…

Everything you show know about ES6 `let` keyword.

Everything you show knows about ES6 let keyword. Both var and let are used to declare variables in javascript, but the difference is that var is function scoped and let is block scoped. In this article, we will see the diffe…

ES6 JavaScript: Understanding Let & Const

Variables can be declared using const in the same way that var or let declarations are. The const keyword turns a variable into a constant whose value cannot be changed. The scoping rules for const variables are the same as t…

How to extract number from string using Linq

Imagine you have an s tring("ABCDE99F-J74-12-89A") , and you want to extract the only number from the string. This snippet will show how to extract numbers from strings. using System ; using System . Collections . G…

C# Boyer-Moore String Search Example

In this article, I will show you the implementation of the ==Boyer-Moore == algorithm. Boyer Moore is a string searching algorithm. It avoids checking most positions in the source string. The implementation here uses constant ch…

Load More
That is All