Leonardo Grando · @lgrando123
111 followers · 375 posts · Server sciencemastodon.com

[BR] Lista com a implementação de mais de 1200 tarefas computacionais em variadas linguagens de programação.
[EN] 1200 tasks implementation in several .

rosettacode.org/wiki/Rosetta_C

#computational #language #programming #rosettacode

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
522 followers · 9230 posts · Server masto.ai
Barry Schwartz 🫖 · @chemoelectric
521 followers · 9210 posts · Server masto.ai

A contribution for -- the old insideness of a convex hull algorithm. I decided to do this because I am likely to stick the algorithm within my next Bézier intersection algorithm (which will be coded in Ada using homogeneous geometric algebra, not in ATS using euclidean, but whatever) --

Find if a point is within a triangle - Rosetta Code rosettacode.org/wiki/Find_if_a

#rosettacode #ats #atslang #mathematics #geometry

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
509 followers · 8329 posts · Server masto.ai

Have at it, nerds and weirdos! A task for y’all:

Bézier curves/Intersections - Rosetta Code rosettacode.org/wiki/B%C3%A9zi

#fonts #graphics #rosettacode #ats #atslang #dlang #maxima

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
510 followers · 8325 posts · Server masto.ai

I wrote a new task of interest to both fans and fans:

Steffensen's method - Rosetta Code rosettacode.org/wiki/Steffense

Incidentally, before being smart and using for the graphic (the only SW I should have considered, aside from ), I tried using the software formerly known as FF, but which did nothing but crash. I mean, really, it did nothing but crash. FontCrash, it will be called.

cc: @khaled

#rosettacode #ats #fonts #metapost #asymptote

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
511 followers · 8324 posts · Server masto.ai

Well, I am not eager to contribute to on a language that is SUCH A moving target.

#rosettacode

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
511 followers · 8311 posts · Server masto.ai
Barry Schwartz 🫖 · @chemoelectric
511 followers · 8265 posts · Server masto.ai
Barry Schwartz 🫖 · @chemoelectric
511 followers · 8259 posts · Server masto.ai

There is a new example at , part of my nascent tendentious series of simulations that show quantum physicists are entirely wrong in some of their beliefs:

rosettacode.org/wiki/Simulated

This code is all or mostly free of the proofs and complicated call by reference you often see in my ATS code. You could translate it straight into OCaml or SML. It is a simulation, supposedly impossible, of experiments you sometimes see hyped in the news, but which are stupid.

#ats #rosettacode #atslang

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
511 followers · 8259 posts · Server masto.ai

Please have a look at my "Extra Credit" problem on --

Simulated optics experiment/Simulator - Rosetta Code rosettacode.org/wiki/Simulated

#rosettacode

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
509 followers · 8254 posts · Server masto.ai

Have at it, fellow computer programming nerds! I have done the (not because I like Python, which I do not, but because so many others know it):

rosettacode.org/wiki/Simulated
rosettacode.org/wiki/Simulated

(I do admit, however, that the library support was quite adequate, for doing a simulation such as this with multiple processes. Most languages, certainly, do not come with such support as part of their compiler/interpreter distribution.)

#rosettacode #python

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
508 followers · 8160 posts · Server masto.ai

Some programming in for . And I mean really , not type hierarchy masquerading as OO. Communicating objects.

There is no type hierarchy, because none is needed. One can use a closure to connect two objects, as long as the connection is compatible at both ends.

And there is just one thread, because why in heck would you need two threads, just to read the time on the clock??????

rosettacode.org/wiki/Active_ob

#realtime #objectoriented #ats #rosettacode #oo #atslang

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
508 followers · 8151 posts · Server masto.ai
Barry Schwartz 🫖 · @chemoelectric
508 followers · 8121 posts · Server masto.ai

I am considering adding a task, ‘BCD integer division with remainder’.

The reason for BCD is that it can be done in more languages than other practical uses of long division, it helps resolve an ambiguity about one of the major steps, and it will let me provide specific test cases.

This division as done by Knuth is quite a complex operation, which I had coded incorrectly for a long time. I had generated the wrong test cases! And so missed my bug.

#rosettacode

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
508 followers · 8115 posts · Server masto.ai

Another example for fans!

rosettacode.org/wiki/Long_mult

This is long multiplication, which I have used here to solve two distinct problems.

The designer of the task must never have realized you could do this in something other than BCD and end up not having a carry ever occur.

#ats #rosettacode #atslang #functionalprogramming

Last updated 1 year ago

Barry Schwartz 🫖 · @chemoelectric
506 followers · 7874 posts · Server masto.ai

This is the ‘Read a PPM file’ task done in , giving you a program for converting color images to grayscale:

rosettacode.org/wiki/Bitmap/Re

One might notice a couple of things. In the current version of all these codes, (a) you do not need a garbage collector, because it’s using linear types, and (b) you do not need the math library and I do not use floating point.

(I temporarily had floating point while I was confounded to find what I was doing wrong with integers.)

#rosettacode #ats

Last updated 2 years ago

Barry Schwartz 🫖 · @chemoelectric
507 followers · 7865 posts · Server masto.ai

Okay, you NUMEROUS fans of , I have done the next step in that set of tasks dealing with ():

rosettacode.org/wiki/Bitmap/Wr

You have to get new versions of the earlier files, if you looked at those before. There is a link to them at the top of this entry.

#ats #rosettacode #pixmaps #bitmaps #atslang

Last updated 2 years ago

Barry Schwartz 🫖 · @chemoelectric
506 followers · 7805 posts · Server masto.ai

I have added another example to , this time for a strangely named ‘Munching Squares’ task:

rosettacode.org/wiki/Munching_

(The reason I say the task is strangely named is that ‘Munching Squares’ is an animation. Perhaps the task is not adequately fleshed out. I did what I thought it wanted.)

#ats #rosettacode #atslang

Last updated 2 years ago

Barry Schwartz 🫖 · @chemoelectric
506 followers · 7791 posts · Server masto.ai
Barry Schwartz 🫖 · @chemoelectric
505 followers · 7784 posts · Server masto.ai

Here is a similar program in -- which is NOT annoying (at least when you aren’t doing anything to fancy) --

rosettacode.org/wiki/Xiaolin_W

#fortran #rosettacode #math #graphicsprogramming #ellipse #evolute

Last updated 2 years ago