Skip to main content
1 of 5

Ruby, 77 chars

def r(w);l=w.size-2;w[1,l]=w[1,l].split("").sort_by{|x|rand-0.5}.join;w;end