How to Run C# Program in Ubuntu

How to install C# Program in Ubuntu. First we need to open ubuntu Terminal. Now here after we need to Write following commands….. 1. sudo apt-get update(or sudo aptitude update ) : It is used to updates local system. Next Command We need to install “mono-runtime” . About Mono, it provides complete CLR ( Common […]

C# Program to Find Sum of Natural Numbers

Sum of Natural Numbers in C#. The Natural number is positive integer. It starts from 1 and increment to infinity : 1,2,3,4,…etc.Sum of Natural Number Means : 1+2+3+5…the basic formula to calculate sum of natural number n(n+1)/2 where n is positive integer.Let’s see the the C# coding to find sum of natural number. Sum of […]

Pattern programs in C#

pattern example in c#. Complete discussion of Patterns in C# Programming. Here i explained different kinds of patterns with running codes. Most interviewer ask different pattern to check logic. so i highly recommend you execute programs and try to understand the codes. Pattern Example 1 Pattern Example 2 Pattern Example 3 Pattern Example 4 Pattern […]

Generate Random Numbers in C#

Random Class : It is used to generate pseudo-random number. Each execution it returns different values. NextBytes : It Fills the elements of a specified array of bytes with random numbers. Random.Next() Method : It Returns a random integers/characters NextDouble : Returns a random floating-point number that is greater than or equal to 0.0 and […]