« first day (130 days earlier)      last day (3073 days later) » 

09:37
@LuisMendo Looking at this challenge, I figured, why not do 0:YY. However, in the Try it online! compiler, the result was Inf. So, I tried 0:YP, which resulted in 3.14... rather than 0,1,2,3. How can I do a range up to a constant? :YP works, but does not include 0.
(note that regardless, the answer would have been invalid since it must start printing on finite memory too)
09:56
@sanchises By default : takes one input x and gives the range 1:x. You want two inputs, so use 2$:or its abbreviated version :&. For example, :& with inputs 3, 7 gives [3 4 5 6 7]. You can also use : in literals (as opposed : to being a function). So 3:7 works too
Yeah I figured 3:7 worked, but I didn't know that e.g. YP wasn't interpreted as a literal but just pushed it to the stack. Thanks.
Anyway, awesome language you created with MATL, once I get the hang of the stack I hope I can beat you properly some day :)
2
11:02
@sanchises Thanks! Welcome onboard! :-)
 
1 hour later…
12:25
@LuisMendo Thanks! Care to give me any obvious golfing tips based on this answer?
13:04
@sanchises Using d is very clever. Saves two bytes over the obvious approach nq:
The last v!1e can be replaced by &h. The meta-function & for h means N$. So &h (or N$h) concatenates the whole stack horizontally.
You may want to add a link to Try it online so people can test it
Or MATL Online (developed by Suever with a bunch of interesting, MATL-specific features), but the latter is still experimental and occasionally freezes
14:00
@LuisMendo How on Earth did I not consider horzcat? I guess I was being stupid due to the fact that the stack is printed vertically... thanks!
 
3 hours later…
16:40
Any thoughts on golfing this one down?
3
A: Output the largest number with the fewest digits

DJMcMayhemMATL, 14 bytes 10&YlktX<=G*X> Try it online! Explanation: &Yl % Log 10 % Base 10 kt % Floor and duplicate X< % Find the smallest element = % Filter out elements that do not equal the smallest element G % Push the ...

 
1 hour later…
17:50
@LuisMendo What would it take to get unicode support in MATL?
@Suever You could substitute the unicodes with (any) ascii characters to demonstrate your language but it would make the answer non-competing — Bassdrop Cumberwubwubwub 10 mins ago
18:16
@Suever I'd like to know that too :-) Matlab supports them, up to code point 65535 I think. Octave apparently doesn't. Maybe there's some configuration possible. Do you have any idea? There must be a way for Octave to support Unicode
18:42
@LuisMendo So Octave naturally "kind of" supports it
I.e. you can do disp('─┐')
If you try to do it with MATL, we get a parse error
Oh wait... no
Although using them in a "matrix" is cumbersome since when converting to double you get 3 values per unicode char matl.suever.net/…
Actually now that I think about it, that's a really sneaky way to create an RGB color....
Also this weekend I'm going to add some code to the site so I can monitor every time we get a freeze
 
1 hour later…
19:56
@Suever Huh. I can't even type or paste that on my Octave. It must be something with my config
@Suever I can't try that on Octave, but Matlab gives
>> double('─┐')
ans =
        9472        9488
which makes more sense. Each char should be a number
20:13
Man, all this terminal / encoding stuff is over my head. I can't even find relevant info using Google
Anyway, I would be happy having it working in the online compiler only (and on my Matlab). But the fact that double('─┐') gives three values per char on Octave is unsettling
As is this comment:
> Octave "by accident" supports UTF-8 ...
Yea the Octrave page on that is hilarious
Yes :-)
MATLAB is at least unicode-aware so it handles it correctly
Octave just does....something
Exactly. And by accident :-D
I could patch double so it gives one number (not three) like Matlab, but it's impossible to patch all of +, * etc for Unicode chars
So we MAY be able to use Java from Octave to handle unicode more naturally
Oh yea it's defintely not worth patching double
I was just trying to see how it treated it
20:20
We can't say MATL supports Unicode when casting a char to number gives such wild results :-(
Octave parses it as basically UTF-24 which isnt' a thing
haha
are you trying to paste it into the octave-gui or cli?
In the Octave GUI when I paste it I get:
double('\342\224\200\342\224\220')
And I can't paste it into MATLAB
 
3 hours later…
23:29
@Suever I tried both
What a mess!

« first day (130 days earlier)      last day (3073 days later) »