Skip to content
loading...

re: Daily Challenge #212 - DNA to RNA VIEW POST

FULL DISCUSSION
 

OCaml:

let dna_to_rna = String.map ~f:(function | 'T' -> 'U' | x -> x)

ReasonML (with Bucklescript):

let dnaToRna = Js.String.replaceByRe([%re "/T/g"], "U");
code of conduct - report abuse