Special Numbers Loops Posted May 09, 2020

Fibonacci numbers are a series of numbers in which each number is formed by adding previous two numbers in the series. For example, we start by 1 and 2, and then repetitively add the add the numbers to result in the next number. For a given max limit 10, we would want to find the first 10 Fibonacci numbers. Series: 1,2,3,5,8,13,21,34,55,89

```
public static List<int> DoGetFibonacci(int n)
{
int a = 1, b = 2, c = 0;
List<int> series = new List<int>();
series.Add(a);
series.Add(b);
while (series.Count < n)
{
c = a + b;
a = b;
b = c;
series.Add(c);
}
return series;
}
```

**How it works:**

The core of Fibonacci series is adding up previous two numbers a and b to form the next number c. Taking this as the base we build the logic and put it in a loop to iteratively generate the series.

Compute and generate a compressed string for a given string containing repetitions

Find all possible natural numbers below a given limit such that a3+b3 = c3+d3

Find all the pairs in a given ordered set of numbers whose sum is equal to a given input sum

Find all the pairs in a given unordered set of numbers whose sum is equal to a given input sum

Sort the given unordered set of Binary digits

Implementing stream based communication with gRPC and ASP.NET Core

Building a simple Client-Server Interaction with gRPC in ASP.NET Core

Role-based and Claims-based Authorization in ASP.NET Core using Policies - Hands on

Understanding How Antiforgerytoken works in ASP.NET Core MVC

Implementing Cognito User Login and Signup in ASP.NET Core using AWS SDK