Skip to content

Instantly share code, notes, and snippets.

@ddeaguiar
Created October 6, 2008 20:19
Show Gist options
  • Save ddeaguiar/15136 to your computer and use it in GitHub Desktop.
Save ddeaguiar/15136 to your computer and use it in GitHub Desktop.
require 'rubygems'
require 'activesupport' # => true
$KCODE='UTF8' # => "UTF8"
s = 'Peña'
t = 'PEÑA'
s.chars.downcase.to_s # => "peña"
t.chars.downcase.to_s # => "peña"
s.chars.downcase.to_s.eql?(t.chars.downcase.to_s) # => true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment