Skip to content

Instantly share code, notes, and snippets.

Aly-Bocar Cissé essic

  • Paris
Block or report user

Report or block essic

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@essic
essic / main.hs
Created Feb 16, 2019
Kata (Haskell) - FooBarQix created by essic - https://repl.it/@essic/Kata-Haskell-FooBarQix
View main.hs
-- http://codingdojo.org/kata/FooBarQix/
{-# LANGUAGE OverloadedStrings #-}
import Data.Text as T
import qualified Data.Map.Strict as M
import qualified Data.Char as C
import qualified Data.List as L
import Data.Maybe (catMaybes, fromMaybe)
newtype Digit = D Text
View install.sh
sudo apt-get update
sudo apt-get install curl -y
sudo apt-get install emacs25-nox -y
sudo apt-get install git -y
curl -sSL https://get.haskellstack.org/ | sh
@essic
essic / main.fs
Created Jun 19, 2018
SimpleFSharpDemo-04 created by essic - https://repl.it/@essic/SimpleFSharpDemo-04
View main.fs
module Implem04
open System
type Age = int
type FirstName = string
type LastName = string
type Person =
{ FirstName : FirstName
@essic
essic / main.fs
Created Jun 18, 2018
SimpleFSharpDemo-03 created by essic - https://repl.it/@essic/SimpleFSharpDemo-03
View main.fs
module Implem03
open System
type Age = int
type FirstName = string
type LastName = string
type Person =
{ FirstName : FirstName
@essic
essic / main.fs
Created Jun 18, 2018
SimpleFSharpDemo-02 created by essic - https://repl.it/@essic/SimpleFSharpDemo-02
View main.fs
module Implem02
open System
type Age = int
type FirstName = string
type LastName = string
type Person =
{ FirstName : FirstName
@essic
essic / main.fs
Created Jun 18, 2018
SimpleFSharpDemo-01 created by essic - https://repl.it/@essic/SimpleFSharpDemo-01
View main.fs
module Implem01
open System
//These are type aliases
type Age = int
type FirstName = string
type LastName = string
//This is a product type : Record
View demo-v0.fs
// In here we want to show informations about collaborators in some consulting organization.
module BasicDemo
//Basic import, useful to access "String" by example"
open System
//This is type alias
type Age = int
type FirstName = string
type LastName = string
View WorriedDarkcyanTransversal.cs
using System;
using System.Linq;
using System.Collections.Generic;
public enum State {
Invalid = 0,
Ok = 1,
Ignored = 2,
NOk = 3,
NN = 3
View Haskell playground.hs
{-# LANGUAGE NoImplicitPrelude #-}
import Data.List (find)
import Data.Monoid ((<>))
import Data.Either (Either(..))
import Data.Int (Int)
import System.IO (IO,putStrLn)
import Data.String (String)
import Text.Show (show,Show)
import Data.Maybe (maybe)
import Data.Function ( (.), ($))
@essic
essic / Haskell playground.hs
Last active Oct 11, 2017
Haskell playground created by essic - https://repl.it/J0S6/16
View Haskell playground.hs
race :: Int -> Int -> Int -> Maybe (Int, Int, Int)
race v1 v2 g
| v1 >= v2 = Nothing
| otherwise =
let ts = convertToSecondsThenFloorIt $ calculateTimeToCatchUpInHours v1 v2 g
h = getHours ts
m = getMinutes ts
s = getSeconds ts
in Just (h, m, s)
where
You can’t perform that action at this time.