Skip to content
Snippets Groups Projects
Commit bd19b121 authored by Tamazouzt AIT ELDJOUDI's avatar Tamazouzt AIT ELDJOUDI
Browse files

buildAbs

parent e92924aa
No related branches found
No related tags found
No related merge requests found
File added
......@@ -103,7 +103,10 @@ def buildAbs(terme):
assert (checkType(terme) == ABS)
input = parseInputFromAbs(terme)
output = parseOutputFromAbs(terme)
if terme [0]!= '(':
return new_abs((buildTerm(input)),buildTerm(output))
else:
return buildAbs(getTermFromParantheses(terme,0))
def buildApp(terme):
assert (checkType(terme) == APP)
......@@ -163,4 +166,4 @@ def remove_multiple_spaces(terme):
# print(findClosingParanthesesIndex('()',0))
#print(remove_multiple_spaces("x y z (#x.z g)"))
#print(buildTerm("x "))
print(checkType("(((#x.x)))"))
\ No newline at end of file
print(buildAbs("(((#x.x)))"))
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment