Commit 6b566f1f by Sartika Aritonang

Upload New File

parent 533307c5
import re
class DisambiguatorPrefixRule18a(object):
"""Disambiguate Prefix Rule 18a
Rule 18a : menyV -> me-nyV to stem menyala -> nyala
"""
def disambiguate(self, word):
"""Disambiguate Prefix Rule 18a
Rule 18a : menyV -> me-nyV to stem menyala -> nyala
"""
matches = re.match(r'^meny([aiueo])(.*)$', word)
if matches:
return 'ny' + matches.group(1) + matches.group(2)
class DisambiguatorPrefixRule18b(object):
"""Disambiguate Prefix Rule 18a
Original Rule 18 : menyV -> meny-sV
Modified by CC (shifted into 18b, see also 18a)
"""
def disambiguate(self, word):
"""Disambiguate Prefix Rule 18a
Original Rule 18 : menyV -> meny-sV
Modified by CC (shifted into 18b, see also 18a)
"""
matches = re.match(r'^meny([aiueo])(.*)$', word)
if matches:
return 's' + matches.group(1) + matches.group(2)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment