This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Control.Applicative | |
import Control.Monad | |
import Data.HashSet hiding (filter, map) | |
import Data.Maybe | |
dictionary :: IO (HashSet String) | |
dictionary = (fromList . lines) <$> readFile "/usr/share/dict/words" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Control.Applicative hiding (empty) | |
import Data.HashMap.Strict hiding (map) | |
import Data.String.Utils | |
data Entry = Entry String String | |
run :: FilePath -> FilePath -> IO () | |
run input output = process <$> readFile input >>= writeFile output |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Control.Applicative hiding (empty) | |
import Data.HashMap.Strict hiding (map) | |
import Data.String.Utils | |
data Entry = Entry { _postcode :: String, _person :: String } | |
run :: FilePath -> FilePath -> IO () | |
run input output = writeFile output =<< process <$> readFile input |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Control.Applicative hiding (empty) | |
import Data.HashMap.Strict hiding (map) | |
import Data.String.Utils | |
data Entry = Entry { _postcode :: String, _person :: String } | |
run :: FilePath -> FilePath -> IO () | |
run input output = writeFile output =<< process <$> readFile input |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Control.Applicative hiding (empty) | |
import Data.HashMap.Strict hiding (map) | |
import Data.String.Utils | |
data Entry = Entry { _postcode :: String, _person :: String } | |
run :: FilePath -> FilePath -> IO () | |
run input output = writeFile output =<< process <$> readFile input |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Main where | |
import Control.Applicative | |
import Control.Monad | |
import Data.HashSet hiding (filter, map) | |
import Data.Maybe | |
dictionary :: IO (HashSet String) | |
dictionary = (fromList . lines) <$> readFile "/usr/share/dict/words" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Test where | |
data ℕ : Set where | |
zero : ℕ | |
suc : ℕ → ℕ | |
id : {A : Set} → A → A | |
id a = a | |
data Bool : Set where |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
template<typename T> | |
void eraseElem(std::list<T>* elements, const T& elem) { | |
for (auto it = elements->begin(); it != elements->end(); it++) { | |
if (*it == elem) { | |
elements->erase(it); | |
} | |
} | |
} |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@cython.boundscheck(False) | |
@cython.wraparound(False) | |
@cython.cdivision(True) | |
def _isotonic_regression(np.ndarray[DOUBLE, ndim=1] y, | |
np.ndarray[DOUBLE, ndim=1] weight, | |
np.ndarray[DOUBLE, ndim=1] solution): | |
cdef: | |
Py_ssize_t current, i | |
unsigned int len_active_set |
OlderNewer