Skip to content

Instantly share code, notes, and snippets.

View pema99's full-sized avatar

Pema Malling pema99

View GitHub Profile
public object CreateInstance(string Name, params object[] Args)
{
Type ToCreate = Type.GetType(Name);
var InnerTypeList = new List<Type>();
InnerTypeList.Add(typeof(CallSite));
InnerTypeList.Add(typeof(Type));
foreach (object Arg in Args)
{
InnerTypeList.Add(Arg.GetType());
@pema99
pema99 / CompactFizzBuzz
Created April 15, 2015 19:55
Compact FizzBuzz
for (int i = 0; i < 100; i++)
Console.WriteLine((0 == i % 3 && 0 == i % 5) ? "FizzBuzz" : 0 == i % 3 ? "Fizz" : 0 == i % 5 ? "Buzz" : i.ToString());