Advertisement
Guest User

Untitled

a guest
Jun 27th, 2017
55
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.52 KB | None | 0 0
  1. static void Main(string[] args)
  2.         {
  3.             long i = 7;
  4.             i = Convert.ToInt64(Console.ReadLine());
  5.             Stopwatch s = new Stopwatch();
  6.             s.Start();
  7.             const double gr = 1.6180339887;
  8.             const double s5 = 2.2360679774997896;
  9.             i = Convert.ToInt64((Math.Pow(gr, i) - Math.Pow(1 - gr, i)) / s5);
  10.             s.Stop();
  11.             Console.WriteLine("F: {0}\nT: {1}", i, s.Elapsed.Milliseconds);
  12.             Console.ReadLine();
  13.             return;
  14.         }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement