Skip to content

Latest commit

 

History

History
71 lines (62 loc) · 787 Bytes

File metadata and controls

71 lines (62 loc) · 787 Bytes

Test case: simple function

JavaScript:

function Test() {
    var tmp = 10;
}

Python:

def Test():
    tmp = 10

Test case: function with multiple lines

JavaScript:

function Test() {
    var tmp = 10;
    tmp += 1
}

Python:

def Test():
    tmp = 10
    tmp += 1

Test case: simple function with return

JavaScript:

function Test() {
    return 10;
}

Python:

def Test():
    return 10

Test case: function with argument

JavaScript:

function Test(arg1) {
    var tmp = 10;
}

Python:

def Test(arg1):
    tmp = 10

Test case: function with multiple arguments

JavaScript:

function Test(arg1, arg2, arg3) {
    var tmp = 10;
}

Python:

def Test(arg1, arg2, arg3):
    tmp = 10