Welcome! This page is using CodeRay 1.1.2.
We currently have
3061 rays
in the database.
You can add a
New Ray
or browse the posted rays by pages.
test |
63 lines
of
Ruby
|
1.43 KB |
Show |
Edit |
Expand |
1
2
3
4
5
6
7 |
class TransactionsController < ApplicationController
def index
@transactions = Transaction.find(:all)
respond_to do |format|
format.html |
|
Sieve of Eratosthenes |
19 lines
of
Ruby
by
Drangon
|
362 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6
7 |
def sieve_of_eratosthenes(max_prime)
sieve = Array.new(max_prime, true)
sieve[0] = sieve[1] = false
2.upto(Math.sqrt(max_prime)) do |i|
if sieve[i]
(i**2).step(max_prime, i) ... |
|
dd |
6 lines
of
Ruby
|
69 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6 |
def way_too_friendly
23.times do
puts 'hi there!'
end
end
|
|
kuper |
1 line
of
Delphi
by
kuper
|
25 Bytes |
Show |
Edit |
Expand |
1 |
5hZJo5 hf6Snb9Ula10Hdf74n |
|
test |
5 lines
of
Plain text
by
aa
|
238 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5 |
select count(*) from cdma_serv@db_jsydtest where region_id=f_get_region;
select count(*) from cdma_serv;
select count(*) from cdma_serv_state_attr@db_jsydtest where region_id=f_get_region;
sel... |
|
song |
23 lines
of
ERb
by
song
|
542 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6
7
8
9
10 |
<html>
<head>
<title>Online Cookbook</title>
</head>
<body>
<h1>Online Cookbook</h1>
<%= @content_for_layout %>
<p>
<%= link_to "Create new recipe",
:... |
|
fff |
2 lines
of
Ruby
by
ff
|
12 Bytes |
Show |
Edit |
Expand |
|
SysConfig |
19 lines
of
Ruby
by
kongfw
|
657 Bytes |
Show |
Edit |
Expand |
1
2
3
4
5
6
7 |
class SysConfig
EXCEPTION_NOTIFIER = {
:delivery_method => :smtp,
:sender_address => %w(beyondrails@gmail.com),
:email_prefix => "BeyondRails",
:recipients ... |
|
c++ |
4 lines
of
C
by
test
|
68 Bytes |
Show |
Edit |
Expand |
1
2
3
4 |
public void main(char** args)
{
cout << "hello, c++" << endl;
} |
|
test |
1 line
of
C
|
4 Bytes |
Show |
Edit |
Expand |
|