This file contains hidden or 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 FrereJacques where | |
| import Haskore.Music | |
| import Haskore.Melody | |
| import Haskore.Basic.Pitch | |
| import Haskore.Basic.Duration | |
| import Haskore.Music.GeneralMIDI as MidiMusic | |
| import Haskore.Interface.MIDI.Render as Render | |
| render_to f m = Render.fileFromGeneralMIDIMusic f song where |
This file contains hidden or 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 ChameleonBass where | |
| import Haskore.Music | |
| import Haskore.Melody | |
| import Haskore.Basic.Pitch | |
| import Haskore.Basic.Duration | |
| import Haskore.Music.GeneralMIDI | |
| import Haskore.Interface.MIDI.Render | |
| pitch_line = map (\(x,y,z) -> x (y :: Octave) z () ) |
This file contains hidden or 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 Mongo where | |
| import Database.MongoDB | |
| import Database.MongoDB.BSON | |
| import Network | |
| import Data.ByteString.Lazy.UTF8 | |
| fS = fromString | |
| db = fS "yourdb" |
This file contains hidden or 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 Text.ParserCombinators.Parsec | |
| runop :: Char -> Integer -> Integer -> Integer | |
| runop '+' n1 n2 = n1 + n2 | |
| runop '-' n1 n2 = n1 - n2 | |
| runop '*' n1 n2 = n1 * n2 | |
| runop '^' n1 n2 = n1 ^ n2 | |
| operation :: Parser Integer | |
| operation = do |
This file contains hidden or 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
| import Char | |
| r = flip mod | |
| b [l] = l | |
| b l = b $ map (\x -> read [x]) $ show $ sum l | |
| s = b . map ((+1) . r 9 . r 97 . ord . toLower) . filter isAlpha | |
| main = do | |
| x <- getLine | |
| putStr $ show $ s x |
OlderNewer