Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions tests/it/script_scope.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,11 @@
import numpy as np

def calculate_cbrt(age):
return round(age ** (1. / 3))
# check whether defined function can import module from global namespace
if round(age ** (1. / 3)) == round(np.cbrt(age)):
return round(age ** (1. /3))

cbrt_age = calculate_cbrt(age)
# cbrt_age = round(math.cbrt(age))
f"The rounded cube root of my age is {cbrt_age}"
"""
StringReader = scyjava.jimport("java.io.StringReader")
Expand Down
Loading