(GMlite only)
if possible, help would be appreciated.
0j0
-
Edited by the potato whisperer, 09 May 2012 - 07:21 PM.
Posted 09 May 2012 - 07:20 PM
Edited by the potato whisperer, 09 May 2012 - 07:21 PM.
Posted 09 May 2012 - 07:42 PM
Posted 09 May 2012 - 07:45 PM
Posted 09 May 2012 - 07:54 PM
first = string_lower('Hey! What are you doing today?')
string_replace_all(first, 'hey', 'pasfe')
string_replace_all(first, 'what', 'sgsg')
string_replace_all(first, 'are', 'sgea')
//...
file_1 = file_text_open_read('English.txt')
file_2 = file_text_open_read('Other.txt')
while (file_text_eof(file_1) == 0){
string_replace_all(string, file_text_read_string(file_1), file_text_read_string(file_2))
file_text_readln(file_1)
file_text_readln(file_2)
}
file_text_close(file_1)
file_text_close(file_2)
Posted 09 May 2012 - 07:57 PM
function repositionAdjective(){
list = text.substring(0,text.length).split(" ");
text = "";
for(a=0;a<list.length;a+=1){
if(partOfSpeech(list[a])=="adjective"){
if(partOfSpeech(list[a+1])=="noun"){
text+=list[a+1]+" "+list[a]+" ";
a+=1;
}
else if(partOfSpeech(list[a+1])!="noun"){
text+=list[a]+" ";
}
}
else if(partOfSpeech(list[a-1])=="adjective" && (partOfSpeech(list[a-2])=="noun") && a>1){
text+=list[a]+" ";
}
else{
text+=list[a]+" ";
}
}
}And for that you'll need a function that returns the part of speech of a word. Which gets complicated for words with multiple parts of speech, such as "jump" (noun), "jump" (verb), or other (the "jump" in "jump drive").Edited by dannyjenn, 09 May 2012 - 08:09 PM.
0 members, 0 guests, 0 anonymous users