Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
T
typon-compiler
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
typon
typon-compiler
Commits
8f0c1646
Commit
8f0c1646
authored
Nov 02, 2023
by
Tom Niget
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add extension example
parent
e8ce3013
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
0 deletions
+17
-0
typon/trans/tests/pyext.post.py
typon/trans/tests/pyext.post.py
+3
-0
typon/trans/tests/pyext.py
typon/trans/tests/pyext.py
+14
-0
No files found.
typon/trans/tests/pyext.post.py
0 → 100644
View file @
8f0c1646
import
pyext
print
(
"Imported:"
,
pyext
.
add
(
5
,
3
),
pyext
.
fibo
(
10
))
\ No newline at end of file
typon/trans/tests/pyext.py
0 → 100644
View file @
8f0c1646
# coding: utf-8
# extension
def
add
(
x
,
y
):
return
x
+
y
def
fibo
(
n
):
res
=
[
0
,
1
]
for
i
in
range
(
2
,
n
):
res
.
append
(
res
[
i
-
1
]
+
res
[
i
-
2
])
return
res
if
__name__
==
"__main__"
:
print
(
"Python:"
,
add
(
5
,
3
),
fibo
(
10
))
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment