Skip to content

Instantly share code, notes, and snippets.

@Xhendos
Created September 14, 2016 19:18
Show Gist options
  • Save Xhendos/9e488ff6abac9c6a7abcf15516ed5037 to your computer and use it in GitHub Desktop.
Save Xhendos/9e488ff6abac9c6a7abcf15516ed5037 to your computer and use it in GitHub Desktop.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
class Program
{
static void Main(string[] args)
{
int[] numbers = AddNumbers(12, 15);
Console.WriteLine(numbers[0]);
Console.WriteLine(numbers[1]);
Console.WriteLine(numbers[2]);
}
private static int[] AddNumbers(int a, int b)
{
int[] data = new int[3];
int result = a + b;
data[0] = a;
data[1] = b;
data[2] = result;
return data;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment