Conversation
Edited 6 months ago

@panicatthebot @green

what exactly do you mean by this?

This project uses no data structures!!

how can you have a program without data structures??? that doesn’t make sense!! all data is structured!!! you have structs!!! it came free with your C compiler!!!!

4
0
0

@sodiboo @green @panicatthebot probably in the same way as mastodon being algorithms free

0
0
2

@sodiboo by that i mean that i don’t use any dynamic arrays and hashmaps/dictionaries. everything is just a char pointer. lots of the code i’ve written in this project is intentionally wasteful, so that i don’t have to store intermediate calculations and such. concatenating strings is O(n^2) because funny.

i have considered that the struct i used (just a pair of strings) breaks this rule, and i can return multiple values in a slightly different way, but i decided that this struct is too simple to be a proper data structure

1
1
0

@green you should replace it with a single char* containing a null terminator after the body, then more data for the cw, then another null terminator. that would be a funny inefficient way to do it I think.

1
0
0

@sodiboo @green @panicatthebot (Sparkles) all structs boil down to elementary types in assembly

0
0
0

@sodiboo that would be a pain to implement. concatenating strings with malloced sprintfs is funny and easy to implement.

this project sorta turned into an exercise on how far i can stretch the one mprintf() function

1
0
0

@green Yeah it would be a pain but it would be funny.

0
0
0

@sodiboo this project solely runs off of good vibes and cuddles

0
0
1