zoomlogo / flax Goto Github PK
View Code? Open in Web Editor NEWflax tacit language
Home Page: https://zoomlogo.github.io/flax/
License: MIT License
flax tacit language
Home Page: https://zoomlogo.github.io/flax/
License: MIT License
Substitue / Replace insides ... whatever.
Takes y as an array and sandwiches x between y[0]
and y[-1]
Example: [3, 4]<thing>[4, 5] -> [4, 3, 4, 5]
quick
Jelly's {}
Like the meanings of terms like "links", "quicks" etc.
Make I
the index generator. Similar to Dyalog APL's iota.
{⊃∘.,/⍳¨⍵}
in Dyalog APL.
If the number is int, convert it to int.
2.0->2
intify=lambda x:vectorised(lambda a:int(a)if a==int(a)else a)
1 -> [1]
[1] -> [1]
[1,1] -> [[1,1]]
Basically the length should be 1 if it isnt already 1.
Make flax right to left like most array languages.
Nilads that refer to the chain's left or right argument.
<something>
Takes the next character's value. Like Vyxal.
<something else>
Takes the next 2 characters.
Users can rlwrap
instead.
Remove the diagraph of reversing the digits.
Now use ⌽
for reverse / reversed range.
And use R
for vectorise reverse / reversed digits.
Use the mpmath
module which is a dependency of sympy.
Also use floats and the mp
context of mpmath
.
The precision will be 20 digits.
The codepage should be rewritten: glyphs will be the same, only their positions will be changed.
Probably this:
x|0123456789ABCDEF
------------------
0|⁰¹²³⁴⁵⁶⁷⁸⁹¶₹«»≡≢
1|лнпя‘’¢£¥€⌿⍀≥≠≤±
2| !"#$%&'()*+,-./
3|0123456789:;<=>?
4|@ABCDEFGHIJKLMNO
5|PQRSTUVWXYZ[\]^_
6|`abcdefghijklmno
7|pqrstuvwxyz{|}~˙
8|ȦḂĊḊĖḞĠḢİĿṀṄȮṖṘṠ
9|ṪẆẊẎŻȧḃċḋėḟġḣŀṁṅ
A|ȯṗṙṡṫẇẋẏż→←↑↓∥∦¬
B|´˝˘¨˜¯¼½¾×⁼∞∝∀∃÷
C|∘○⟜⊸∊∴∵∂⊂⊃⊆⊇⊏⊐⊑⊒
D|αβγδεζηθικλμνξπρ
E|ςστυφχψωΩ⌈⌊⌉⌋ØÆŒ
F|√∑∏⊢⊣⊤⊥∧∨∪∩⍋⍒øæœ
NOTES:
- ¶ is a newline
[1, 1]
[0, 0]
[-1, -1]
[-1, 1]
[[0, 1], [1, 0], [0, -1], [-1, 0]]
I'm not sure which command i choose, but "⍴" In APL.
Probably a diagraph
For each an every element, there should be a unit test.
Makes spotting bugs wayy easier.
Using this decorator:
def fix_default_args(f):
return lambda *args: f(args[0], args[1]) if len(args) == 2 else f(None, args[-1])
Since some lambdas use the ugly looking lambda w,x=None:
which will confuse me in the future.
Implicitly join by newlines until a flat array.
Indented printing by default.
To disable P
flag
both diagraphs:
Use /
instead of \
for replicating and make it like APL.
26
, glyph -> subscript 7
Some diagraphs would be cool.
Check if it is between the ascii values of 0 and 9.
N: Nilad, M: Monad, D: Dyad
SB: Single byte, DB: Diagraph
Q: Quick
ALL DONE!
Refactor and clean some functions.
Filter by
Better random. (vectorises)
Ŕ
turns into ?
, which functions similar to APL.
0?
Gives a random floating number from 0 to 1.
s?
Turns s
into a range and selects one randomly from that.
Also don't use things like map
, use list comprehensions where possible.
similarly to strings, complex numbers (and floats) should also be overloaded for many builtins.
W
to act on multidimensional arrays.builtins.py
.*_link(
overload atoms.¹c
flag.¹ Modify monadic_link
and dyadic_link
to accept overloads=fdict
where fdict is like:
{
"num-num": lambda w,x: w+x,
"str-lst": ...,
"str-any": ...,
"num-any": ...,
"any-any": ...,
}
² For this I will use my own implementation (which I might copy mostly from Vyxal).
⌽
flax/error.py
holds the error handling stuff.
Porbably a single byte monad
It would be pretty cool.
New idea, documentation will be in the repository.
The website will be like APLCart.
icfs
regular.APL's @
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.