csc410's Issues
No need of assignment in the functional language
https://github.com/weiboi/csc410/blob/250d4cac1b659cd07062f76902c96594d4b184bb/func_ast.py#L144
An assignment is a let binding!
No need of return statement in the functional language
https://github.com/weiboi/csc410/blob/250d4cac1b659cd07062f76902c96594d4b184bb/func_ast.py#L505
Functions don't return anything - they reduce to expressions.
Specify version of Python to use
With Python 2.7, checkin4.py returns an error because you use os.fsencode(..)
. You should specify the version of Python you are using if there are incompatibilities.
No empty statement in functional language
Output without condtionals
In the ouput from checkin4.py, I get:
Input:
if(cond > 0) {
if (cond2 < 0) {
a = a + 1;
} else {
a = a + 2;
}
b = a * a;
} else {
b = c + 2;
}
Output:
fun code_block(cond, b, a, c, cond2) return (b, a)
let a = a + 1 in let a = a + 2 in let b = a * a in let b = c + 2 in (b, a)
There should be conditionals in the function ?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.