Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
24 lines (18 sloc) 516 Bytes
using System.Collections.Generic;
using System.Linq;
namespace DangerousAssumptions.SlowPerformance
{
public class FibonacciReader : IReader<int>
{
public IReadOnlyCollection<int> GetItems()
{
return new FibonacciSequence().ToList();
}
// Comment out this method to use the default implementation
// from the interface
public int GetItemAt(int index)
{
return new FibonacciSequence().ElementAt(index);
}
}
}
You can’t perform that action at this time.