Skip to content

Instantly share code, notes, and snippets.

@nikasulo
Created September 3, 2019 23:16
Show Gist options
  • Save nikasulo/2a9f61acc02a2eed14f71bb8418e0e9a to your computer and use it in GitHub Desktop.
Save nikasulo/2a9f61acc02a2eed14f71bb8418e0e9a to your computer and use it in GitHub Desktop.
brute force solution
while string.include?('gn')
string.gsub!("gn", 'ng')
end
puts string
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment