\usepackage[super,sort&compress,numbers]{natbib}
This results in reference numbers as shown below

i.e. some stuff and junk about Python, Perl, Matlab, Ruby, Mac X, Linux, Solaris, ...
\usepackage[super,sort&compress,numbers]{natbib}
This results in reference numbers as shown below
#!/opt/local/bin/ruby
(0..5).each {|x|
puts x/2
}
0
0
1
1
2
2
#!/opt/local/bin/ruby
(0..5).each {|x|
puts x.to_f/2
}
0.0
0.5
1.0
1.5
2.0
2.5