Skip to content

Instantly share code, notes, and snippets.

Fabien Arcellier FabienArcellier

  • Octo Technology
  • Paris
Block or report user

Report or block FabienArcellier

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
@FabienArcellier
FabienArcellier / BitmapInfo.cs
Created Nov 28, 2012
Class in C# to extract pixel map from a specific channel
View BitmapInfo.cs
using System.Drawing;
namespace PictureHistogram
{
/// <summary>
/// Class that expose method to get pixel map from a specific channel
/// </summary>
class BitmapInfo
{
private Bitmap m_bitmap;
@FabienArcellier
FabienArcellier / .htaccess
Created Dec 2, 2012
Disable indexaction or block access to a directory in htaccess file
View .htaccess
# disable directory browsing
Options All -Indexes
# Deny access to this directory for anybody
Order allow,deny
Deny from all
@FabienArcellier
FabienArcellier / install_composer.sh
Created Dec 9, 2012
Install composer on linux machine
View install_composer.sh
sudo curl -s https://getcomposer.org/installer | sudo php -- --install-dir=/usr/local/bin/
@FabienArcellier
FabienArcellier / index.php
Created Dec 9, 2012
Autoload namespace manually from silex
View index.php
<?php
$loader = require_once __DIR__.'/vendor/autoload.php';
$loader -> add('Application', __DIR__); // PSR-0 autoloading, the directory '__DIR__/Application' must exists
$app = new Silex\Application();
$app->run();
?>
@FabienArcellier
FabienArcellier / disable_unc_check.reg
Created Dec 11, 2012
Disable Unc Check in register database
View disable_unc_check.reg
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Command Processor]
"DisableUNCCheck"=dword:00000001
View famille.prolog
/* Programme sur les liens familiaux */
pere(paul, jean).
pere(paul, frederic).
pere(emilie, marie).
pere(jean, andre).
pere(jean, cathy).
pere(jean, francis).
pere(frederic, marc).
pere(frederic, lisa).
@FabienArcellier
FabienArcellier / menu.prolog
Created Dec 14, 2012
Create menu with price and calories associate with it
View menu.prolog
entree(salade, 5, 400).
entree(taboulee, 3, 300).
plat(andouillette, 8, 500).
plat(steak, 10, 900).
fromage(bri, 3, 150).
fromage(camembert, 4, 300).
dessert(tarte, 5, 320).
View list_contains.prolog
% list_contains(5, [1,2]) % Renvoie false
% list_contains(5, [1,5]) % Renvoie true
list_contains(X, [X|_]).
list_contains(X, [_|R]):- list_contains(X, R).
@FabienArcellier
FabienArcellier / factorielle.prolog
Created Dec 20, 2012
Calculate a factoriel using prolog
View factorielle.prolog
fact(0,1).
fact(1,1).
fact(X, Result):- X > 1, X1 is X-1, fact(X1, Result1), Result is Result1 * X.
@FabienArcellier
FabienArcellier / fibonacci.prolog
Created Dec 20, 2012
Calculate fibonacci suite
View fibonacci.prolog
fibo(1, Result):- Result is 1.
fibo(2, Result):- Result is 1.
fibo(X, Result):- X > 2, X1 is X - 1, X2 is X - 2, fibo(X1, ResultN1), fibo(X2, ResultN2), Result is ResultN1 + ResultN2.
You can’t perform that action at this time.