Skip to content

Instantly share code, notes, and snippets.

@dgonzo
dgonzo / FRED
Created June 8, 2012 03:14
Federal Reserve FRED Java API
cPropertyURIProperty
public static final java.lang.String cPropertyURIProperty
System.getProperty(cPropertyURIProperty) returns the URI of the property file. Define this on the java command line. For example, if your properties file is fred.properties then the command line should be
java -Dcom.uniservsolutions.stlouisfed.fred.properties="fred"
It is also necessary that the classpath contains the directory fred.properties is in.
The properties it's looking for are these:
# FRED API parameters
fredAPIKey=<api_key>
@dgonzo
dgonzo / Week4Ex3.rb
Created May 24, 2011 19:23
Method call from ternary
@byes = 0
def prompt(*args)
print(*args)
gets.chomp
end
def random_year
rand(21) + 1930
end