Open QFSW opened 5 years ago
Taking the following fragment of C
return 3 / 2;
This would yield 1 as it it performs integer division When converting this to Python, do we want to keep the integer division (ala Python 2) or do we want to use the Python 3 / behaviour that would yield 1.5?
1
/
1.5
I don’t think division operation need to be supported in the translator as it is not in the spec.
Taking the following fragment of C
This would yield
1
as it it performs integer division When converting this to Python, do we want to keep the integer division (ala Python 2) or do we want to use the Python 3/
behaviour that would yield1.5
?