« first day (32 days earlier)      last day (80 days later) » 

05:43
Okay, got all of the arithmetic and exponentiation/root/logarithm stuff working, and cleaned up the code a bit
 
1 hour later…
06:51
Oh very nice
Oh but it's not on the repo
Very sad
At the moment the parser is a bit broken and none of the operators are bound to code points
I should be able to get back to work on the fun part now, which is implementing the operators, so a lot of progress should be made tomorrow
Anyway it's late here so o/
 
9 hours later…
15:45
Should pad("string", 10, "abc") be "stringabcabc" or "stringabca"?
 
3 hours later…
18:23
definitely the latter
I suspect that the cases in which you need the former would be marginal
although I guess that goes for both
I think what's most important about a pad function is what you get out is the length you asked for
although by that logic maybe it should truncate the input if the given length is shorter
 
2 hours later…
20:31
Currently I have three operators to factor an integer.
Factors: Returns all numbers > 1 and < n which are factors
All factors: Returns all pairs of numbers which multiply to n (this includes 1, n, and possible duplicates)
Prime factors: Does what it says on the tin
Do y'all think these make sense, or should I change them?
They make sense to me at least, although you might want to keep the first one a 2-byte builtin for now and see how often it's used
20:47
For reference here's a list of sample outputs
I'll probably keep the first one as a one byte operator, since it makes sense with the other operations it's overloaded with, I might just make a few changes to what it outputs
Makes sense
Outputting proper divisors instead of all divisors can be pretty useful, I just figured you could take the list of all divisors and keep only the middle
Should I just make the factors one return proper divisors? The all_factors one will have duplicate ones for perfect squares, which requires another byte to filter out.
21:05
I guess adapting all_factors would be too many bytes then, so yeah
It wouldn't be too many bytes (three, I think), but proper divisors are probably more useful than the current version of factors
Just to clarify, this definition of proper divisors doesn't include 1, right?
It usually does
It would probably save bytes on a lot of factoring related challenges
Like fo perfect numbers
Oh hi Lyxal
21:27
Howdy
All factors seems to be a bit unsuitable for a one byte
Proper divisors seems good for a single byte
Pirme factors is good for a byte too
I think all factors has its uses, though.
It's the shortest way to determine if a number is a perfect square, for example
duplicates(all_factors(x)) returns sqrt(x), for perfect squares only
@RedwolfPrograms I was suggesting maybe have it as a two byte
I still have a ton of available spaces for number operators, I don't want to unnecessarily make things two bytes
I'm just wondering if there's a better function available than all factors for one bytes
Such as?
For aesthetic/ease of remembering purposes, I've got factors/all_factors/prime_factors overloaded to combinations/permutations/orderings, so it'd probably have to be something factoring related
21:35
@RedwolfPrograms oh it's on an overload
That's all right then
Pretty much everything is, other than basic arithmetic stuff and string/array concat
I thought you meant all fact would be a stand alone function
No, I wouldn't waste a byte on that :p
Good

« first day (32 days earlier)      last day (80 days later) »