Skip to content

Instantly share code, notes, and snippets.

Avatar

Bjarki Ágúst Guðmundsson SuprDewd

View GitHub Profile
View keybase.md

Keybase proof

I hereby claim:

  • I am SuprDewd on github.
  • I am suprdewd (https://keybase.io/suprdewd) on keybase.
  • I have a public key whose fingerprint is C2B7 124F 1002 CB7E 9EB5 7FD6 4C89 3F0D 004B 3101

To claim this, I am signing this object:

View SieveOfEratosthenes.cs
using System;
using System.Collections.Generic;
using System.Linq;
namespace Primes
{
public static IEnumerable<int> SieveOfEratosthenes(int upperLimit)
{
int sieveBound = (upperLimit - 1) / 2,
upperSqrt = ((int)Math.Sqrt(upperLimit) - 1) / 2;
View OutputCssFiles.php
<?php
// Output contents of all css files.
foreach(scandir(dirname(__FILE__)) as $f)
{
if (substr($f, strlen($f) - 4) == '.css' && is_file($f))
{
// do something with css file like:
//echo file_get_contents($f);