public ActionResult PrimeSearch(int PrimeSearchValue) { var sieve = new PrimeSieve(PrimeSearchValue); sieve.ComputePrimes(); var values = sieve.ToArray(); ViewBag.PrimeNumbers = values; return(View("Index")); }