How can I capitalize a string in rascal?
In the documentation of the string library, I can not find any method to capitalize a string.
http://tutor.rascal-mpl.org/Rascal/Rascal.html#/Rascal/Expressions/Values/String/String.html
You should use the toUpperCase
function in the String
library, detailed here:
For example:
rascal>import String;
ok
rascal>toUpperCase("hEllO WOrlD");
str: "HELLO WORLD"