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
#!/usr/bin/env ruby | |
class Array | |
def flat | |
inject [] do |memo, current| | |
if current.kind_of? Array | |
memo += current.flat | |
else | |
memo << current | |
end |
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
public class Calculator { | |
public static String[][] values = { | |
{ "CM", "DCD" }, | |
{ "M", "DD" }, | |
{ "CD", "CCCC" }, | |
{ "D", "CCCCC" }, | |
{ "XC", "LXL" }, |
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
<html><head><!-- emp: 19 de junio --> | |
<title>ConeCta CuaTro, por Roberto Morales </title> | |
<style> | |
.c4{background:#000000} | |
h1{background:black;border-bottom:3px ridge red;margin:0;padding:0;font-style:normal; font-variant:normal; font-weight:normal; font-size:40px} | |
h4{background:black;border-bottom:3px ridge red;padding:0;font-style:normal; font-variant:normal; font-weight:normal; font-size:20px; margin-left:0; margin-right:0; margin-top:0; margin-bottom:10} | |
a{cursor:hand;text-decoration:none;color:lime} | |
a:hover{background:#11aa11;cursor:hand} | |
td{font-size:16px;font weight:bold}</style> | |
<script lang="JavaScript"> |
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
<html><head><!-- emp: 19 de junio --> | |
<title>ConeCta CuaTro, por Roberto Morales </title> | |
<style> | |
.c4{background:#000000} | |
h1{background:black;border-bottom:3px ridge red;margin:0;padding:0;font-style:normal; font-variant:normal; font-weight:normal; font-size:40px} | |
h4{background:black;border-bottom:3px ridge red;padding:0;font-style:normal; font-variant:normal; font-weight:normal; font-size:20px; margin-left:0; margin-right:0; margin-top:0; margin-bottom:10} | |
a{cursor:hand;text-decoration:none;color:lime} | |
a:hover{background:#11aa11;cursor:hand} | |
td{font-size:16px;font weight:bold}</style> | |
<script lang="JavaScript"> |
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
# 25 de feb 2012 | |
def fizzbuzz_value ( input ) | |
o = '' | |
o += 'fizz' if( input % 3 == 0 ) | |
o += 'buzz' if( input % 5 == 0 ) | |
o = input.to_s if( o == '' ) | |
o | |
end |