Contact: aviboots(AT)netvision.net.il
41,599 questions
54,241 answers
573 users
using System; class Program { static int Square(int x) { return x * x; } static void Main() { int x = 10; Console.Write(Square(x)); } } /* run: 100 */
using System; class Program { static double Square(int value) => System.Math.Pow(value, 2); static void Main() { int x = 10; Console.Write(Square(x)); } } /* run: 100 */
using System; class Program { static int Square(int x) => (int)Math.Pow(x, 2); static void Main() { int x = 10; Console.Write(Square(x)); } } /* run: 100 */