Remove string utilities already in MJS

This commit is contained in:
Willy-JL
2024-03-17 05:45:57 +00:00
parent 10a03e0cc1
commit 19b5f35afb
2 changed files with 4 additions and 102 deletions

View File

@@ -1,15 +1,15 @@
let sampleText = "Hello, World!";
let lengthOfText = "Length of text: " + to_string(GetLength(sampleText));
let lengthOfText = "Length of text: " + to_string(sampleText.length);
print(lengthOfText);
let start = 7;
let end = 12;
let substringResult = substring(sampleText, start, end);
let substringResult = sampleText.slice(start, end);
print(substringResult);
let searchStr = "World";
let result2 = to_string(indexOf(sampleText, searchStr));
let result2 = to_string(sampleText.indexOf(searchStr));
print(result2);
let upperCaseText = "Text in upper case: " + toUpperCase(sampleText);