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
sudo pacman -S npm | |
sudo npm install --unsafe-perm -g elm elm-test elm-oracle elm-format | |
sudo ln -s /usr/lib/libtinfo.so /usr/lib/libtinfo.so.5 | |
# Add this to your .vimrc if you use Vim with Vundle: | |
Plugin 'ElmCast/elm-vim' |
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
use std::fmt; | |
#[derive(Copy,Clone)] | |
enum CellState { Dead, Alive } | |
impl fmt::Display for CellState { | |
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { | |
let printable = match *self { | |
CellState::Alive => 'x', | |
CellState::Dead => ' ', |