Python is an interpreted, dynamically typed, object-oriented programming language. It is open-source, and was originally released in 1991 by Guido van Rossum.
Here's a sample Python method to get started with syntax:
module Denvar | |
def self.lookup key | |
@lookup.call key | |
end | |
def self.activate! &block | |
@lookup = block | |
class << ENV | |
alias :orig_lookup :[] |
define :rvm_install do | |
url = "https://rvm.beginrescueend.com/install/rvm" | |
bash "installing rvm stable" do | |
user params[:name] | |
code <<-EOH | |
bash < <(curl -B #{url}) | |
EOH | |
not_if "which rvm" | |
end |
require "stateful" | |
class Folder < ActiveRecord::Base | |
include Stateful | |
# ... | |
stateful do | |
state :active | |
state :inactive |
(ns roulette.core) | |
(defn spin [] | |
(int (rand 38))) | |
(def *bankroll* (atom 1000)) | |
(defn dobet | |
[bets] | |
(let [winner (spin)] |
EMACS = [ | |
1, | |
2, | |
3, | |
] | |
EVERYONE_ELSE = [ | |
1, | |
2, | |
3, |
#!/bin/sh | |
BRANCHES=`git branch` | |
if [ $? != 0 ]; then | |
exit | |
fi | |
GIT_SVN=0 | |
git branch -r | grep 'git-svn' > /dev/null | |
if [ $? = 0 ]; then | |
GIT_SVN=1 |
from redis import Redis | |
r = Redis() | |
r.publish("greeting", "Neil") |
Ruby is a dynamic, truly object-oriented language (everything is an object) that is also influenced in many ways from concepts found in functional programming. It open source, and was first released in 1995 by Yukihiro “matz” Matsumoto. The most current version is 1.9.1.
Here's a sample Ruby method to get started with syntax:
#!/bin/bash | |
sudo su - | |
# | |
# Audio: fix ubuntu 9.04 broken sound | |
# | |
apt-get install build-essential xmlto libncurses5-dev | |
export ALSA="1.0.20" |