Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Fibonacci Modified
//Rextester.Program.Main is the entry point for your code. Don't change it. //Compiler version 4.0.30319.17929 for Microsoft (R) .NET Framework 4.5 using System; using System.Collections; using System.Linq; using System.Text.RegularExpressions; using System.Numerics; namespace Rextester { public class Program { public static void Main(string[] args) { //Your code goes here string[] input = Console.ReadLine().Split(' '); int t0 = Int32.Parse(input[0]); int t1 = Int32.Parse(input[1]); int n = Int32.Parse(input[2]); BigInteger [] t = new BigInteger[n]; t[0] = t0; t[1] = t1; BigInteger tn = 0; for(int i=0; i<n-2 ; i++){ BigInteger m = t[i+1]* t[i+1]; tn = t[i] + m; t[i+2] = tn; } Console.WriteLine(tn); } } }
run
|
edit
|
history
|
help
0
Pyramid using C#
Kopi Ping Menu
compiled prog
2.1 Basic types: Lists and Linq beauty
count-letter-frequencies
BFS ALGO
operator overriding
c# kum saati
reversearr
Create Sealed Class Object & call sealed method with non sealed class