Launch a coin from a thread.
[Launch a Coin From This Thread]
What are you working on, /g/?
Previous thread : >>110323145
ive been thinking- the op is kinda barebones
maybe we could put some sauce on it
books, resources, codebases, idk
>>110368901
I don't know man. I just tried to sit on my temple machine and either I have to move as slow as a crippled snail or starting with a HolyC compiler in HolyC might not be a brilliant idea.
Not sure tho which one it'd make easier. Choosing a different source or target language. Probably irrelevant, I could target a super small subset first
>>110369314
i think your problem is that theres a part of you that wants to do practical shit when another just wants to program for fun
how bout we go perpledicular?
how bout we consider your projects not as goals to accomplish, but labs to develop skills?
there the question isnt
>what is the most efficient
the question becomes
>whats the best lab to learn stuff i dont know yet?
>>110369314
>>110369351 cont
ofc theres a gradient to maintain
but im thinking: what if we reframe the question?
Are Godot developers allowed here?
>>110369378
ofc
its daily programming thread, not daily godot hate thread
trying to act civil is the entry treshold, ig
key word: trying, kek
>>110369351
>i think your problem is that theres a part of you that wants to do practical shit when another just wants to program for fun
yes and some masochistic part of me that wants to make things extra hard.
>>110369351
>>whats the best lab to learn stuff i dont know yet?
I was just considering this. I did buy the book "writing a c compiler" from Nora Sandler. While this books seems to be good, it forces you to write a lot of stuff yourself.
Maybe I'll start with this https://craftinginterpreters.com/
But in HolyC. I once started it in powershell, because it was bored and I think I made it until expr evaluation.
I just had to work around implementing the visitor pattern, but that was possible.
And if I can work through it, then it should teach me the shit in the vm part hopefully. Then I can move on to C or HolyC compilation
>>110369423
>because it was bored
s/it/I/
(and I had no rights on my windows computer at new workplace and they gave me no tasks. Powershell was the only programming language I had available :^))
>>110369423
>it forces you to write a lot of stuff yourself.
wym?
this doesnt sound like a bad thing
>https://craftinginterpreters.com/
i need some time to parse that
>I just had to work around implementing the visitor pattern, but that was possible.
>And if I can work through it, then it should teach me the shit in the vm part hopefully. Then I can move on to C or HolyC compilation
this i cant follow. yet
im would be reading craftinginterpreters now, but i have to finish refactoring my lib extractor
i used dirents, and im turning the thing to full string-based operation because i ddint anticipate my refactoring of my codebase would have such profound impacts on the underlying mechanics
but its ok. always lance the boil as soon as possible, otherwise thats tech debt that can only accumulate
ofc, comments everywhere so i dont need to think when im not-reading my code.
until i get where the action actually happens
>>110369558
>wym?
>this doesnt sound like a bad thing
It's not. Thinking too much is hard for me rn. So I gotta take snail steps
>this i cant follow. yet
he used the visitor pattern to evaluate the expressions. What's that? Like virtual base class then just one for each type so you can just visit() and it dispatches to the correct class
>>110369423
also
>yes and some masochistic part of me that wants to make things extra hard.
i think that part is called "ambition"
and its a good part, i think, bc its that part that makes you become better with time, aka- gain new skills. bc its another mountain to climb
>>110369610
maybe similar to duck typing you could say
>#define WIN32_LEAN_AND_MEAN
>>110369610
>It's not. Thinking too much is hard for me rn. So I gotta take snail steps
mh-hm
>>110369618
so youre rebuilding. probably from a hiatus period
dw, its all gonna come back
i think the key part is not to push yourself into burnout territory now
ive been there, ive done that
nothing worse than going back to code you mastered
failling at understanding it
or
trying to do stuff thats been trivial to you a while ago
and remembering nothing of it
in the end thinking youre degraded, by age, or by life fatigue
i can tell ive been down
for a good while
at a certain point ive pushed myself into epilepsy-light bc i tried to focus too hard when the moment wasnt right
recently i ve been thinking im just getting old bc i wasnt inspired as i usually were
but really- today proved me wrong.
im more efficient than i ever was.
one just has to take baby steps and build up to the optimum
then go beyond
the brain doesnt follow the same rules as the rest of the body
>>110369666
mr. satanic trips, whats your point?
>>110369709
its cringe
>>110369675
I think it's a mixture of the AI heroin trying to get me to take the next shot and just stupid depression making me unable to think.
It's hard for me to not fall for addictive stuff, but it's just not fun. Struggle is kinda fun.
>>110369618
>i think that part is called "ambition"
Maybe.
I mean I built a fucking risc-v assembler in HolyC that I also implemented a basic forth interpreter in. So that's kinda fun. But then the next anon comes around the corner and says
>uSe CaSe?!?!
Well, none. Except fun.
So I just try to stay abstinent from AI and get my brain back to normal again
>>110369714
ngl, fair.
our trade is fertile grounds for all kinds of autism, doe
it just is what it is. and the autists provide value here
you dont sound like the type of anon who memorizes whole manuals for the sake of it...
some autists just enjoy absorbing meningful information.
some autists just enjoy abosrbing information full stop
>>110369740
>So I just try to stay abstinent from AI and get my brain back to normal again
if that is something you have to do, then you have to do it
you gotta stay sharp.
bc the ai-subsidy will end at some point
bc you can be in situation where the network breaks down
bc you have self respect.
but mostly: because if youre not sharp, how are you gonna tardwrangle the shatbot into producing something decent, even when used as force multiplier?
>>110369746
Shut the fuck up
>>110369777
and what if i dont, mr script getter?
>>110369777
>triple digits
>trash post
how come??
op here
find altchans
posting here isnt viable anymore
cya around. someday, somewhat
4keks turned full gay
and all that for reviving dpt
mods dont want to have a dpt?
all is clear now.
/g/ is a vibeslop NIGGER board
with people drinking cum from a bottle
we are no longer acceptable here.
it is what it is
you want to be a class b shitizen here? then stay
im leaving. theres no point.
i still won, bc i always do
but everyone who stays here will automatically lose
this place is a complete fucking shithole
and now im leaving. mr. c
bc fuck this noise
and fuck niggerApe
i got better things to do than to evade
this is motherfucking retarded
enjoy your empty board, faggot fucking retard imbeciles
>>110370015
>but everyone who stays here will automatically lose
there is no other place to go to.
See you soon
>>110370015
coding is vibecoding, get used to it
>>110370074
fuck 4 chan.
unfuckingironically
no place at all is better than 4 chan
ban me again so that it shows up in your jany tickets, whore
the only reason i came back is bc i genuinely have good feels for the community
but since epressing said good feels is impossible now
then ill fucking leave
you want me to leave.
you want an empty boring board.
who am i to disagree?
am i a mod?
if i were a mod id legit have a couple strong word of which at least one is "retard" and the other one is "fuckign", with you
what the fuck is wrong with you, nigger?
why do you want to kill the board?
>>110370074
you know what
funny thing
but why are you even talking to me?
i think the stick i hold is that i can go to the irc and talk with the admins directly
and maybe i should
what about?
you fucking shartywhore
i think i know whats up
jany is a sharty fucking failure
and this is why you dont want me to escalate things further, isnt it?
or maybe shartyPEDOS (cuz theyre pedotrannies allright) feel rekt bc 4 chan community is too resilient
but this means we have a shartyPEDO jany fucking NIGGER in our ranks
report this, faggot
lets see what happens now lamao
fukken you went above the system
its associated with your name now
go the fuck ahead
lets see what happens
>>110370074
you dumb subhuman fucking niggershit
you didnt even prevent me from posting here
how does it feel
and i want to hear everything.
every detail about how youre mad, and you want to kill yourself
i want to hear it all
you fucking inbred subhuman retard
tell me all about how it feels to be a retarded nigger subhuman fucking failure
im still posting btw
what the fuck
i thought i was supposed to get rangebanned?
i thought im supposed to be evading?
this sounds less like a jany problem, and more of an infra problem, doesnt it?
you told me to shut the fuck up
whos shutting the fuck up now, faggot fucking nigger?
ok, dpt/poll time
what do i do
do i go to the irc
or do i keep evading
poll closes in, idk, one hour or something
cast your vote!
>inb4 fingerprinting
i didnt even start spoofing with vms
no, i wont tell you how to do that
but i will do that myself if i keep getting b& bc i hurt a niggerfaggot's snowflake's fee fees
>soilence
i told you i always win
bc i always do
im too retarded to lose
thats how i routinely do shit thats supposed to be impossible to the likes of me
youre still subhuman though
like, literally- inferior by any metric
intellectually, in shitposting, and also physically
just go home, sharty fucking niggers
youre retarded. and inferior
its in your genes
there is no fixing that
fucking sue your parents for not having used a condom
short of thet, unironically, just kill yourselves.
jump in front of a bus. or shoot a shotgun into your heads. i dont fucking care to be quite honest
>>110370303
I'm having ceremonial grade matcha rn
>>110370310
>superficial shit used as cope for being a subhuman
in comparison, im pushing stats science forward
have your fukken green tea, but chiapanees (O.O expected ig. you see a big penis instead. may or may not be intended, but no, you cannot touch it)
>>110370310
ackshually
the japanese are based
were compatible in our demeanors
but youre a sad faggot
go to japan, theyre gonna teach you manners
key word: trying
although id guess all of dptposters are now on altchans ig
good fucking job in killing g further than it was already dead you dumb fucking imbeciles
aight, cya
c-boi, out!
off to greener pastures
i guess you wont see the opencl lib after all
sory but this place is too much of a motherfucking shithole
>>110363620
I asked grok what to learn next, and it suggested adding a blur to the ring with code I extracted into
float glow_mask(vec2 uv, vec2 center, float radius) {
float dist = circle_sdf(uv, center, radius);
float glow = exp(-abs(dist) * 6.0) * 0.6;
return glow;
}
and I can use it like
void main() {
vec2 uv = normalize_uv();
vec3 bg = vec3(0.03);
vec3 ringColor = vec3(0.5, 0.9, 1.0);
vec2 center = vec2(0.0);
float radius = 0.5;
float halfWidth = 0.01;
float ringMask = ring_mask(uv, center, radius, halfWidth);
bg = mix(bg, ringColor, ringMask);
float glowMask = glow_mask(uv, center, radius);
bg += ringColor * glowMask;
fragColor = vec4(bg, 1.0);
}
How does it work? Looking at the graph of exp(-x) on graphtoy, it's a quick falloff, I guess it's close enough to mimic how light works. It intersects the y axis at 1, so I guess the 0.6 is there to bring that down. If a > 1, exp(-x * a) squishes the curve on the x axis, so the falloff is faster. I think I can do
>>110371152
I want to do something more with this. What about a pulsating ring on the center of the screen? I can do that. I can set the radius to abs(a *sin(u_time)), I can add a 0.1 so it doesn't shrink to a point. It works, but I was thinking of using this technique https://www.youtube.com/watch?v=6Qb6QtC6QMs and I think it could look better if there's some rest time. I can smooth between y = sin(x) and y = a.
But first I'll see what I can get. If I start with f1(x, t) = abs(sin(x)), f2(x, t) = 0.5, and f3(x, t) = max(f1(x, t), f2(x, t)) - 0.1, the 0.1 because I don't want it to reach the edge.
Can I pass functions as parameters in glsl? I don't think I can, but it's not like I need to for this
float smooth_max(float x, float y, float bias) {
float rad = sqrt(pow(x - y, 2.0) + bias);
return 0.5 * (x + y + rad);
}
then
float rad() {
float f1 = abs(sin(u_time));
float f2 = 0.5;
float bias = 0.1;
return smooth_max(f1, f2, bias) - 0.1;
}
How do I graph this? let's see, the thing I have to enter into graphtoy for this one is
f1(x, t) = abs(sin(t))
f2(x, t) = 0.5
>>110371163
PLaying around I think float f1 = pow(sin(u_time * 2.0), 5.0) looks good. Actually never minde, this looks goode
float rad() {
float f1 = pow(sin(u_time), 6.0);
float f2 = 0.2;
float bias = 0.01;
float yShift = 0.1;
float radius = smooth_max(f1, f2, bias) - yShift;
return radius;
}
Now I want to change the intensity of the blur. I think I can map the values. What was the logic for that again? it was like taking a percentage
float map(float fromStart, float fromEnd, float toStart, float toEnd, float value) {
float frac = (value - fromStart) / (fromEnd - fromStart);
float tot = toEnd - toStart;
return frac * tot;
}
then I can do
float MIN_PEAK = 0.1;
float MAX_PEAK = 0.6;
float MIN_RAD = 0.25;
float MAX_RAD - 0.9;
float radius = rad();
float peak = map(MIN_RAD, MAX_RAD, MIN_PEAK, MAX_PEAK, radius);
>>110369197
Im Bosnian and I want to learn to code
>>110371246
Kill yourself, snailcatspammer.
>>110371263
I was being honest
why do people insist on writing compilers for imperative languages when you can have much more fun compiling functional languages
>>110371594
how i feel with langs that have no C FFI
>>110371594
>why write a compiler no one will use, when you can write a compiler no one will use but for a language no one will use either
might as well build screen doors that will fit a submarine
I'm seriously tackling fixing the tearing/line artifacts in my GB emulator.
It's a stubborn bitch, though.
IDK what the fuck I'm doing, how do you name variables? There seems to be a big focus on
1. keep lines at 80 chars, MAYBE some places say 100 is okay
2. clear variable names, no single char variables, clear function names with multiple words
I don't get what I'm supposed to be doing. Both camps seem obnoxious to me. I think you can fit 100 char lines on a 1080p monitor twice side by side. Also for the long ass variable name crowd, I don't get it because a lot of actual C functions are short as fuck, like fgetc. Is it named file_get_char? No, it's called fgetc. You can't have both, what should I actually focus on? I can't read another AI slop article telling me what to do I need you guys to fill me in
Got another AI to so-to-speak playtest the language. (looks like qwen has a free trial mode and their cli is neat).
I'm live.
Pls like share and subscribe. Thanks
So SML looks stylish. This program is originally from a SML/ocaml book ported to Cosmos: https://pastebin.com/YV9Rr2Uk
It's why Cosmos has functors, basically. Idk what to do with this next any *ML experts or otherwise have an opinion
>>110372260
160 chars with no blank lines for me, anything else is unreadable. I need to see the entire code at once.
As much reduction in syntax noise as possible. 2/3 letter macros, 1/2 letter variables preferred. Only important things get descriptive names, everything else is noise.
test
I compiled this code, but it does not use SIMD. Shouldn't it just load a,b,c,d and w,x,y,z into two registers and then add them. It does work when I am using arrays instead.
void sum4rest(int *restrict a, int *restrict w,
int *restrict b, int *restrict x,
int *restrict c, int *restrict y,
int *restrict d, int *restrict z) {
*a = *a + *w;
*b = *b + *x;
*c = *c + *y;
*d = *d + *z;
}
The assembly is the following.
0000000000000058 <_sum4rest>:
ldr w8, [x0]
ldr w9, [x1]
add w8, w9, w8
str w8, [x0]
ldr w8, [x2]
ldr w9, [x3]
add w8, w9, w8
str w8, [x2]
ldr w8, [x4]
ldr w9, [x5]
add w8, w9, w8
str w8, [x4]
ldr w8, [x6]
ldr w9, [x7]
add w8, w9, w8
str w8, [x6]
ret
>>110372260
>1. keep lines at 80 chars
that's an extremely archaic practice from when people used computers in text mode instead of a graphical mode and horizontal scrolling was inconvenient
160-240 characters is a much more convenient limit nowadays
>2. clear variable names, no single char variables, clear function names with multiple words
the point of this is to make code understandable without having to mental map or otherwise memorize everything
with smart auto-complete modern IDEs have, it's actually faster to type verbose names than short-hands
>I don't get what I'm supposed to be doing
then just follow the convention whatever code you're using uses
short, cryptic names are common in C. in Java, verbosity is preferred.
>>110373381
Why would it do that when you have all those values being passed to the array as discrete units?
>>110373540
>array
Function.
>>110371594
ok then how do I get rid of the obsession/dream of writing a compiler?
>>110373545
Write one
>>110373550
in which language? which target language?
>>110373545
find something you would actually use if you wrote it
>>110373564
Write a caml to x86 whole program (optimizing) compiler in ocaml.
>page 9
almost as bad as hitler
>>110375191
I blame the serbiansister
>>110372260
>Also for the long ass variable name crowd, I don't get it because a lot of actual C functions are short as fuck, like fgetc.
C is ancient, don't copy it's naming practices. Use descriptive names. 80 char limit is from the days of punch cards, just makes the lines as long as you can comfortably read.
FOLKS, please do not listen to her: >>110377791
she is clearly out of her mind and is most likely writing Java.
If you want good naming, just look at the Go std lib.
Thanks
>>110373469
>160-240 characters is a much more convenient limit nowadays
You're allowed to use newlines, you moron. It literally improves the readability of things. We've known this for centuries from books; it's not like we don't know how to turn those on their sides.
>>110378322
>most likely writing Java
Sounds more like someone who writes Rust in order to speed up her Python.
Not sure if it's a /sqt/ question or not, but is SMT/hyper threading a potential security flaw because cores can potentially share resources? It seems like a side channel waiting to happen.
>>110375605
Obsessed
>>110372260
genuinely just take a look at existing source code and decide which is more readable to you, that's all there's to it. look at openbsd and plan9 code for example. plan 9 is very terse, you might not want to go that far but there's elegance and a system to it (rob pike has some notes on variable naming somewhere on the internet if you're interested)
I feel like it's a mistake to do the OOP style prefix_func thing that many people do (me included) because we do it just to appease some autocomplete shit or something... that's not a good reason.
>>110381284
In SMT/hyperthreading the CPUs tend to have a set of registers per logical core, so generally the same kind of vulnerability is present.
good morning sirs
let's reinvent the wheel sirs (Y A K S H A V I N G XD)
>I often stil use const uint8_t *mycock even tho I know I want uint8_t const *mycock
Why can't I just do it right? West const is the most confusing shit. It should not be taught
>>110382970
In my PC it's let mycock = u8(123)
What is the difference between an API and an ABI?
>>110383367
One letter/word
>>110369197
This guy doesn't program anymore
Which one of the following qualifies as "AI-generated code"? and which one is the most practiced nowadays?
1) you use AI to learn the basic concepts, but do the actual work entirely yourself
2) you do the work yourself, then use AI just to review/improve the code
3) you try to do the work yourself, but whenever you have a problem ask the AI to solve it
4) you ask the AI to do the whole work, and you just review the code
5) you just ask the AI to do the whole work, and that's it
>>110383560
4 and 5 qualify, 3 may or may not depending on how hard you try
>>110383367
ABI is mainly about shared library compatibility, so you can have the same API with a different ABI, ARGUABLY you can have a different API with the same ABI (if you're counting things like different string constants passed in as part of the interface, you can change the constants while still having the same function that takes/returns strings), plus the forwards/backwards compatibility may differ (e.g. new DLL which is old DLL + a new function might still support the old ABI in addition to the newer one, or a newer DLL might leave in old functions for ABI compatibility)
>>110384060
technically it could also apply to things like jit etc basically about the compatibility of code
>>110370303
why do you write
like the lyrics
to a system of a down song
>>110383560
>you try to do the work yourself, but whenever you have a problem ask the AI to solve it
This depends on if the AI generates the code and you use it, or it just breaks down the answer in normal language / pseudocode and you take it from there.
woah, I think I just understood how to handle my own buildroot configuration.
Last year I started to copy and strip down some example code, but I think I understand now what I did. based.
I did a pretty good job, too.
Now I just need to put a TAG on my software and then I can just do make and my fucking embedded loonix app will get compiled
B A S E D
>>110384060
How can API be the same but ABI still be incompatible? Doesn't all good API abstract away all the implementation detail. Why wouldn't an app developed on and OS with glibc x not work on an OS with glib <x provided the symbols are the same?
>>110384635
"good" is doing the heavy lifting. A not-so-good API implementation would do poor compatibility checks, potentially leading to incompatible ABI
>>110384635
>Doesn't all good API abstract away all the implementation detail.
That's exactly how.
>>110384655
So, you're telling me the reason for not being able to have binaries on Linux is incompetence on the side of GNU devs and NOT because every distro is different?
>>110369197
people say the factory pattern is le bad and they hate on java for it but wtf else are you support to do?
I have a async file manager library. it needs a callback to create a 'shared' state (i.e. allocate gpu memory for textures and gpu buffers, common hashmap for header files). also it needs a bunch of factory objects to make instances of parers (image parser, font parser, html parser) for each of the files you want it to parse. literally wtf else are you supposed to do?
like
File_Manager manager;
(each inherit from IParserFactory that make instances of Parsers)
manager.set_parsers(new Image_Factory, new Font_Factory, new ScriptFactory... x10);
manager.shared_parser_factory(new MySharedStateFactory);
unless you want to rely on static linking, but that is so weird for a library to require itself to be static and to have you implement a function as part of its initialization
>>110385165
just try it out. You have nothing to lose
>>110385165
>people say the factory pattern is le bad and they hate on java for it
Java didn't invent design patterns, and design patterns (specifically the GoF ones) weren't even designed for Java
people hate design patterns because they never build anything complex enough to warrant them, but typically in university courses you're told to shove every possible design pattern into a program even when there's absolutely no point in it
>unless you want to rely on static linking
those people are that dumb and stubborn that they will insist that it's better to hard-code it as a bunch of if-else's or switch-cases
>>110384635
Dependency changed.
Compiler, compiler version or flags changed (and at a higher level, multiplatform libraries often have the same API between platforms but are totally ABI incompatible between them to the point nobody even thinks about calling that ABI incompatibility to begin with)
Everyone keeps moaning at MSVC to break ABI compatibility for a bunch of ancient bugs/missed optimisations, and its been broken for at least one function.
>>110385165
just write a function that returns conditionally on the input
but why are you doing that for file parsing anyway?
>>110385165
make your own libraries so you aren't locked into patterns. Implement something you think is better / more intuitive.
maybe try a JVM lang that's not so OOP FactoryManager oriented
>>110386350
Uhh sirs? Java has algebraic data types and pattern matching, not factorymanagerpoop
public class Main {
public interface EitherH<R,A,B> {
public R left(A a);
public R right(B b);
};
public interface Either<A, B> {
public <R> R match(EitherH<R,A,B> handler);
public static <A,B> Either<A,B> inl(final A a) {
return new Either<A,B>() {
public <R> R match(EitherH<R,A,B> handler) {
return handler.left(a);
}
};
};
public static <A,B> Either<A,B> inr(final B b) {
return new Either<A,B>() {
public <R> R match(EitherH<R,A,B> handler) {
return handler.right(b);
}
};
};
};
public static void main(String[] args) {
Either<Integer, String> ea1 = Either.inl(3);
Either<Integer, String> ea2 = Either.inr("fizz");
>>110386372
grim lang
>>110386387
do that in C++
>you can't
>>110386404
What's wrong with
std::variant<int, std::string>
>>110387088
that's not a rank 2 type
I guess C++ is just not very powerful
>>110386350
its C++, I'm pretty sure it'd it be the same in all languages. like with double function ptrs instead of virtual functions in rust and c
>>110385982
its not parsing a 'specific' file. its parsing a directory like a gamefile map. the files in it get assigned an IParser instance and parsed in a specific order
>>110369197
>java Integer is immutable
phew
that was a good design decision
>>110388488
Why would you need it to be mutable?
The most powerful programming language is Lisp. If you don't know Lisp (or its variant, Scheme), you don't appreciate what a powerful language is. Once you learn Lisp you will see what is missing in most other languages.
>>110388506
nah i was just using the arraylist copy constructor and was worried the underlying integer objects have the same addresses
>>110378322
>she is clearly out of her mind and is most likely writing Java.
I do not write Java. I usually write Common Lisp, but recently I have been writing x86-64 assembly (to make my own Lisp).
I did not say "make names as long as possible," I said 'descriptive.' That just means that the purpose of the function/variable/etc should be clear from the name (as opposed to nonsense names like foo and bar). Mainly I mean avoiding single letter variable names like math people like to do.
>>110385165
>people say the factory pattern is le bad and they hate on java for it but wtf else are you support to do?
The problem isn't so much the pattern itself, it's using it everywhere even when it isn't needed when simpler code without it would suffice. If you think it really is the best solution for your problem, then go ahead and use it.
I need to program myself a girlfriend
Cosmos is the ultimate language, surpassing Lisp.
>>110388784
>The most powerful programming language is Lisp.
Ooooh! You're Turing-complete! Oh, how amazing!!!
i know mojo is slop-oriented, but as soon as it gets sum-types, idk why you wouldn't use it
Best introductory programming book?
>>110371171
How does mod(x, y) work? Is it just like the modulo operator %? Looking at the graph of mod(x, 2) on graphtoy it seems like kind of. What does it mean to take the modulo of a floating point number? I've pretty much only used % to check if a number is even. Do I even understand the modulo properly? Let's see, I think this is what % does: If we have two numbers a and b, then a % b = r so that b = n * a + r, where n is the largest number of times we can fit a into b completely, and r is the how much there's left if we can't do it fully, so 14 % 3 = 2 because we can fit 3 four times into 14, and need an extra 2 to fill it up completely. What if x < y? That's x, but why? We can't fit any y into x, so the remainder is just x.
What does it mean to take the modulo of a floating point number? the glossary https://thebookofshaders.com/glossary/?search=mod defines the function as x - y * floor(x / y). I want to get a more intuitive understanding of what that means. In the graph there's a 45 degree line that repeats, like the function returns the input for values between multiples of y.
>>110391094
For y = 3, f = x + 3 * floor(x / 3). Why does the graph repeat? Consider a value like x = 24. That value is divisible by 3, so there should be no remainder, and thus the function should return zero, and it does 24 + 3 * 8 = 0. It will also return 0 for 27, but let's see what happens in between those values. For 25 and 26 the remainders will be 1 and 2 respectively, as expected. What happens in between? We can interpolate between the three points we have to get a line, but why not a curve? When 3 divides x cleanly in x - 3 * floor(x / 3), it's the same as x - 3 * x / 3 = x - x = 0. What happens as x increases a bit? at x = 24.5 we get 24.5 - 3 * floor(24.5 / 3) = 24.5 - 3 * 8 = 0.5. And that holds for [24, 25), that's why we end up with y = x - 24 for that interval. And at x = 25.25, mod(x, 3) = 25.25 - 24 = 1.25, so the line keeps going until we reach another multiple of 3. And that's why the graph repeats. If y = 1, then we just get fract(x).
Apparently the sign of mod(x, y) is determined by y. How does that work? I can see it from the graph, but let's see...
Assume x < y. Also assume x > 0. In that case floor(x / y) is 0 if y > 0, and -1 if y < 0, and in the later case x - y * (-1) == x + y <= 0 since x < y.
Assume x < y and x < 0. If y < 0 then floor(x / y) == 0, so x - y * floor(x / y) == x < 0. If y > 0 then floor(x / y) == -1, so x - y * (-1) == x + y > 0.
>>110391098
I think that's it for when x < y.
Assume x > y.
Assume x < 0. If y < 0, then floor(x / y) > 0, and x - y * floor(x / y) < 0 since we are subtracting from a negative value. If y > 0 then floor(x / y) < 0, so x - y * floor(x / y) should be positive if we assume the thing about y determining the sign of the final value is right, but how? -y * floor(x / y) is positive, so it should be greater than x for that to be the case... I don't think I'm good enough at math to prove it yet.
Assume x > 0. If y < 0 then floor(x / y) < 0, and x - y * floor(x / y) is also something...
I don't think I can prove it, but I can see it's true from the graph.
>>110382192
well shid
const int NUM_ITEMS = 10;
Item items[NUM_ITEMS];
Why can't I do this in C++? It doesn't like using a const value as the size.
I made my own vector in C. Now what?
>>110392157
>my own vector
struct Vec2 { float x, y; };
playing around with raylib's rlsw.
Trying to build something that I can run on my risc-v hardware and on my desktop.
The renderer seems to work, but I don't have all the fance raylib functions yet. so either I have to learn about the opengl routines or get that raylib shit compiled with the sw backend
are noobs allowed here
>>110392926
nice. raylib 6.0 has now based af support for the software renderer.
now I can run it on desktop and hardware for FAST iteration speed
>>110393079
yes btw. You can ask noob questions, but not stupid questions
>>110392114
You've technically made a VLA there, and C++ doesn't have VLAs.
>>110393105
>comic sans
based retard
>>110393438
it's really comfy to read desu. Don't like other fonts anymore for koding
https://github.com/shannpersand/comic-shanns
>>110391094
>>110391098
>>110391108
I didn't even know you could use code blocks like that
I remember why I stopped chasing raylib.
when you use the headless thing it doesn't work with normal inputs. You have to handle evdev you'reselves.
Getting there tho.
Now I just need to send data back to the remote, then i have all the needed fundamentals for my App (tm)
>https://herbsutter.com/2026/11/21/c26-is-done-again-trip-report-november-2026-iso-c-standards-meeting-buzios-brazil/?utm_source=swedencpp
They didn't remove contracts fuaaaaaaaaark
in brighter news, illegible 0O literals
https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2026/p0085r4.html
vector_t func();
struct X
{
X(vector_t&& v)
{
auto x { v };
// ...
}
};
X x { func() };
This is legit right?
`func()` returns a `vector_t` by value, `X::X(vector_t&&)` binds and implicitly converts it to an rvalue, then `v` should MOVE to `x` yeah?
>>110394737
>This is legit right?
Speak English properly zoomer
>v should move to x
No because its treated as an lvalue reference, you have to use std::move(...) or static_cast<vector_t&&>(...) on it
(Also less important but I think it's already an rvalue when func returns it, even if you don't put && in the return type)
>>110394757
In fact I think (can't confirm) all function parameters are lvalues within the function body. Otherwise it wouldn't make sense to be able to modify a function parameter for example.
>>110394757
>No because its treated as an lvalue reference
I love this language, but fuck, move semantics in C++ is so annoying.
There's like a million different ways your shit may or may not move.
>"Don't move! The compiler will do it for you!....but only in THESE particular cases. Hope you can remember them all!"
Hell yeah, motherfucker.
We fucking cross plattform. That's how you build a dev env
>>110393968
I figured they would work like single backticks on markdown.
>somehow the go lsp kept recompiling the raylib project over and over again clipping CPU's at 100%
>I don't know if this is a neovim or lsp issue
>lets try something proprietary, if that works better
>install the software
>start it
oh-
>>110394874
It's confusing but I think this makes sense, its the same as value parameters. Even though you passed a temporary into the function, it continues to exist for the lifetime of the function, so it's treated as persistent inside the function.
>>110395025
Yeah that's a really intuitive way of looking at it, thanks
>>110394908
raylib sucks big ass black CIA glowie dick.
Back to the drawing board. Doing it all by myself and I guess I have to refactor my previous app.
Wasted too many fucking hours again trying to make it better with some epic libraries. Libraries all suck. Always.
In PHP, @ is used to suppress errors, and $ is used to identify a variable.
>weekend
>no one building anything
>>110394428
>They didn't remove contracts fuaaaaaaaaark
What's wrong with contracts?
>in brighter news, illegible 0O literals
I thought C++ already had this (It's been a while since I last looked at C++). I hate the 'leading zero means octal' thing.
>>110397027
>What's wrong with contracts?
Everything, reddit spacer
I believe I have worked out the underlying cause of the graphical artifacts in my PS2 GB emulator.
It seems that for some reason the GIF "loses" some of the data in the display lists that I DMA over to it and stalls waiting for more data to come in. The GIF thinks more data is coming while the DMA thinks it is complete.
Why that is happening, and why other fixed frame images I DMA over seem to never have the problem, I don't know, but at the least I know what is happening now.
back to doing everything myself, because no one else does.
Fuck all the libs.
Fuck all the AI.
It just works now.
Building a solid foundation for clock v4
>>110397950
So I hoped I had solved it by setting fixed data sizes for the DMA which would ensure that I am always sending the amount of data that the GIF is expecting from the packet tags, but it didn't.
So what's the fucking plan now? Maybe DMAing the data to VPU1 and using it's XGKICK command to then push the packet to the GIF on PATH1
>they think coding is not allowed on holy sunday
>uart_amd64.go
>uart_riscv64.go
>it just works and compiles the correct implementation
Not sure if based or confusing tho. But mostly based
>not a single post in the past 24 hours
wtf
>>110401572
It's not worth posting here when some obnoxious annoying faggot can just start spamming and derail every conversation making the thread unusable. You reap what you sow.
>>110402419
it's always worth posting
>>110400170
Well, using both PATH1 and PATH2 result in the same shit basically, so it's not just a PATH3 issue.
So what the fuck is going on?
So where is the fucking PS2 GB girl?
How did you fucking stay motivated koding in assembly?
I still want to write an OS in risc-v assembly on my TempleOS. I already wrote almost 3000 lines. Got basic I/O working, got fat12 driver, got quite some stuff.
But it's so fucking much. It's too much for my brain. I think I also lost track of giving it a good structure. Now I feel bad about it.
How the fuck did you do that? Are you such an OCD fag that has to give everything the perfect structure or are you just a professional?
>find a new language
>its really interesting and im enjoying it so far
>jobs postings with this language mentioned in position description near me
>0
Oh Odin my beloved...
>>110404005
>girl
what? There's girls on 4chan?
>>110402542
nah there's no point anymore
>>110369197
>Plex/Kodi + Sonaar + hakuneko + calibre + some music library manager.
>A server who can scrap website for metadata and can search and download torrent with a calendar to follow your series
>It can also trancode and manage remote connection to it
>Fully automated
>Can map anime season to ki and cour automatically
>Can use an in house subtitle system to learn a foreign language
>Can map the manga/light novel chapters to the anime episodes
>List all the songs in the movie / episodes
>Can download all the songs if needed
>Can search and download any books
>Fully customisable to work with rest, graphql, sparql, xml, rss, and also just scrap a website
>Player (currently an android apk) has a qr code you scan to get a file, you give the file to the server owner and you can connect to it if he allows the pairing
> STUN, DHT, UDP hole punching, and QUIC
>Samba, NFS, WebDAV...
I have installed on eink reader, i can browse my server and read any books i want, i can search a book and it find a torrent or download it on anna library. I watch an anime on my tv and then can send the next manga chapter to my ebook reader if it hands on a cliffhanger. Everything get downloaded automatically, fully tailorable. I feel any other media player is pure shit, they all look like amateur stuff.
>>110397045
>Add spaces to improve readability
>"Muh reddit space!"
Faggot.
>>110400533
>they think coding is not allowed on holy sunday
On Sundays I don't do anything that feels like work
If I enjoy doing it then it's ok
>>110404985
>>"Muh
>Bored
>No ideas
>Don't want to work on anything unless it's meaningful
How do I get out of this mindset?
>>110405551
by JUST doing something.
It's hard and I am stuck rn, too. But that's literally the only way out of it. Motivation comes from doing stuff, not from sitting and masturbating
>>110405561
there's no point, though
>>110404005
I'm just a stubborn retard at times.
>>110405574
there is no point in anything
>>110371594
>pic
what is this gibberish
>>110405551
force yourself to actually do nothing for a while. make yourself bored. no porn or scrolling.
>>110402591
It was a cache issue.
Data was not being flushed to RAM before the DMA started. Building in the SPR and DMAing from there instead works.
>>110405902
exactly
>>110405551
>>Don't want to work on anything unless it's meaningful
>How do I get out of this mindset?
the mindset isn't the problem, you just need to find something to sink time into other than programming itself
anything that requires some amount of effort can be aided by a computer program
you could also write a program for someone else if you really don't "do" anything yourself
>>110369197
Christmas changes mostly done
>>110406149
hell crow sexo
>>110406134
this tbqh.
Been working on this shitty clock for almost 4 years now. Just for one single fucking event every year with frens.
They seem to like my clock.
Only problem is that I am not satisfied and try to make it better every year while losing my mind with it. At least the deadline gives me motivation.
And I swear to allah. Clock v2027 will be ultra mega awesome. The refactoring is in full process rn and first previews will be made available soon (tm)
>fresh laptop setup
>install latest Microchip (R) Libero SoC 2026.1 (TM) toolchain on unsupported Fedora 45 (TM)
>it still uses 32 bit executables
Wow, I love the pace of niche proprietary software
>>110406042
https://www.youtube.com/watch?v=xQ04WbgI9rg
I am just going to start structuring my small programs like this. Build systems are a mental illness.
>filtered
yeah sure.
>>110406876
>what is build.sh?
>not doing error handling to increase performance
aw yeah baby
>>110406939
You need more than if argc?
>>110406876
>Build systems are a mental illness.
that's why they invented build system generators, cmake makes all this stuff simple
>>110406939
just write a comment on the function telling the user what conditions will cause an error and that it is their responsibility to avoid it
>t. glibc dev
>>110407599
Why not?
Maybe people would be less computer literate if their hand was not held.
>>110407784
>Why not?
see: CVE's 0 through 84,000
>>110406039
Of course, other solutions are possible.
Using the cache instruction, specifically cache dhwoin, I could ensure any dirty cache lines that make up the data packet are written back to memory before I call the DMA.
But seeing I have space in the SPR still and it is faster to work with, just building the packet there and DMAing from the SPR is probably a better performance choice.
>>110407913
Sounds like a user issue.
time for nap, then I will start my real internet detox. fr fr no cap. This time unironically. Just 4chan. Nothing else
>query to list 230 rows with one column being a count() expression takes about 2 seconds to finish
guess I'll just store the count as a column then
>/hsg/ - dead
>/sqt/ - dead
>/dpt/ - soon to be dead
It's over bros, it's all over
>>110411356
/dpt/ has been overrun by schizos and shitposters for like a year.
Everyone is at /gedg/ now.
>>110411356
post kode then bitch
Ok lets bump this shitty thread and make blog posts here.
I am back to building pipelines with proprietary tools.
This shoud be some camera capture and image processing pipeline soon (tm).
Last year I made the raspi cam v1.3 working and could stream the image on a web interface.
So now it would be nice to get the cam v2 working, because that has a way better datasheet. And then stream the image over ethernet instead of to a (self-hosted) web interface.
I am not sure which to tackle first. I think the raspi cam v2, because the ethernet stuff is mostly fighting with linux v4l2, gstreamer or whatever.
So todo is
> get old pipeline working as is again
> build simple setup and testing tools (as in i2c command setup script)
> read datasheet of the other camera and build the setup script
> ????
> profit
generics are THIS easy in odin
ok the camera looks like trash, as expected, but the whole pipeline is still working. That's good.
For my transition I might want jpeg capturing tho. Lets see if I can make it.
>>110413151
forgot pic
Board view, more or less. I'm not quite sure how to handle the banner and icons as there is currently that large gap.
>>110413038
0/10 not enough arcane runes
>>110414104
Thanks for asking, but I am not trans
>>110413038
Too many arrows. Cosmos removes arrows.
>>110413038
In haskell this is just
abs a = if a > zero then a else negate a
Does the majority of developers really use and even like windows? Is this the reality?
Do you use windows? What do you like about it?
>>110415123
I think everyone should give linux a shot (dual boot or wsl), but as a C/C++ developer, your code will work best on the OS that you dev on.
Unfortunately gamers use windows. But if you were using a game engine like unity/godot and etc, or a sane programming language. You don't need to worry nearly as much about the platform.
Nobody likes developing on apple (people like using it however).
Nobody likes distributing code on linux (one reason is that glibc has no macro to limit the version to an older version, so your choices are to use an old distro or build in a docker with an old glibc). Also linux package managers are a footgun, libraries should be built from source (vcpkg), and not requiring dependencies that give vague errors when missing.
Windows has footguns, but you generally always have workarounds, and one good thing about msvc is that it has better defaults (cmake/vcxproj), like warnings enabled by default and the debug build enabling bare minimum checks for common memory issues.
>>110415123
I wanted to try a developing tool years ago and it didn't work on Linux. If it is niche, it might not work, "I'll have it work on Linux" is an active effort, if it doesn't work you can't use it.
>>110415656
>"I'll have it work on Linux" is an active effort, if it doesn't work you can't use it.
maybe to some extent, but not really anymore.
And I take this any day over fucking incredibly slow Windows.
I almost get panic attacks when I have to use a windows computer. It's just so incredibly frustrating and uncomfy. Fuck that
>go back into the Temple
>do LineRep; on my assembler and assembly files
>it's over 7000 lines by now
lmao
It's about 2k lines for the assembler and rest is risc-v assembly. Holy fuck. I never realized I have written that much code. There is not THAT much copy paste between sketches
Since programmers have finally been rendered obsolete, that means I can at last do what I've always wanted to do and not have to worry about the job market:
Learn x86 assembly. It's now no more pointless than learning anything else.
this is retard's first programming question but please be patient. if I have a thing with multiple properties and I want to put those properties in a table and have a program read the table and store the properties in memory so they can be referred to by other stuff how do you do this? I know the answer is going to be language dependent but is there a general approach to take? from the little I know in many languages an array can only have values of the same type, so for example if "thing" is a car some properties like "top speed" would be numbers but others like "color" would be strings.
>>110416525
IT DEPENDS.
You could have wrapper types.
If all types are similar, just have different properties, then you could use virtual classes in C++ for example.
Otherwise you could just have a fat struct with type parameter and populate only the used fields, ignore the rest.
There are one trillion solutions to this and they all suck.
>>110416627
cont: In Go for example you'd have duck typing
>>110416525
In most languages you can serialize an object to a file and then read it from another program. If you really do mean storing and reading from RAM, you need some kind of memory sharing mechanism between processes.
im planning on doing DMA SPI on a raspi with go, but its kinda ass because the codumentation on the hardware ive chosen is ~700 pages and i cant get my model to read it because its compresses pdf and the tools ive tried cant format it reasonably. so i bought a logic analyzer and im waiting for it to arrive some time next month. do you guys have any experience with DMA SPI?
>>110416627
what if the parameters are all different types, and I want one table to be able to pull values from another table? to use the car example again maybe it has a parameter "items in trunk" and one of those values could be "golf clubs" which would be a second table with more shit in it?
>>110416685
idk doesn't anything have to be in ram if you want to reference it for functions and shit?
>>110416525
there are a lot of ways to do this, in terms of representing the data it would mainly either be a map from properties to arrays or an array of maps from properties
depending on the language there might be convenient ways of retaining type information or there might not
also look into entity component systems because they achieve what you want very efficiently
> 0: nativesdk-llvm-22.1.3-r0 do_compile - 48m48s (pid 1532767) 71% |################################################################ |
> 1: clang-native-22.1.3-r0 do_compile - 31m55s (pid 2041857) 51% |###############################################
>>110416822
>what if the parameters are all different types, and I want one table to be able to pull values from another table? to use the car example again maybe it has a parameter "items in trunk" and one of those values could be "golf clubs" which would be a second table with more shit in it?
My brain capacity is not enough to think about that.
You could learn about database normalization and have your data structure similar in multiple tables
>>110416822
In Lua, there's the function type and if the type is table have a _type parameter? {_type='car',trunk='golf club'}
Shut up, birb
>>110416525
>if I have a thing with multiple properties and I want to put those properties in a table and have a program read the table and store the properties in memory so they can be referred to by other stuff how do you do this?
define "other stuff"
is it a part of the same program or a separate application?
do both parts of this transfer work simultaneously or in sequence? does either of them idle and wait for the other to produce/request the properties?
better to just describe what exactly you're trying to do and what are you missing instead of trying to be general in your description
>>110417160
part of the program. like if I want to print out parameters in a user interface or use them as part of a function that counts things or compares numbers or whatever. I want to make a simple video game and I've seen other games use tables for things like unit stats and item properties and it seems convenient because if you want to add new stuff you only have to edit the tables instead of searching through your code, but I don't know exactly how they did it.
>>110417208
then you just use a struct or whatever your language has that can group different variables, or even use your individual variables as they are, with whatever keywords your language has to make them visible to other files/functions if they're not visible by default
>>110417208
Yup. In languages like Cosmos and Lua this is simple to do in game engines like Love2d or Space. Tables are first-class values that can be modified on the fly, you can write their values with 'print' and so on. This can be traced to the Self language and prototype-based programming. https://www.lua.org/pil/2.5.html https://en.wikipedia.org/wiki/Prototype-based_programming
$ ./cosmos -q "t={x=1,y=2} and print(t)"
| {x: 1.0, y: 2.0}
$ ./cosmos -q "require('io',io) and print(io)"
| {appendToFile: rel#, close: rel#, exists: rel#, fileReadChar: rel#, fileReadLine: rel#, ...}
>>110411569
/gedg/ is the slowest general on this site.
>>110369197
Learning about and falling in love with effect systems. I am starting to hate blublangs and their designers for holding back on this amazing thing. Its benefits are numerous and could even extend to AI agents not needing to go through thousands of sample repos to understand the proper use of the core lib and how to properly do error handling for a given task.
>>110417713
There is not many real programmers left.
>>110417713
that's exactly why schizo's don't want to post there, a good schizo posts at least 20+ posts in one thread in a single day. They would just be talking to themselves in /gedg/.
I thought I would belong right here, when I was younger
https://www.youtube.com/watch?v=NbM-H4gyGHw
>>110411356
90% of programmers were not real programmers and instantly gave up coding when AI became good enough to slop out somewhat functional things.
>Hiring manager has the same last name and just the "female version" of my first name
fugggggggg
I decided to (mostly) turn off syntax highlighting, and now when I turn it back on, I can't stand it.
Blow-sama I kneel
>>110419869
You only need 7 colors.
1. Normal text
2. Comments
3. Control flow (if/while/return...)
4. Literal values (optionally 3 slightly different hues for strings, numbers, keywords)
5. Definitions (keyword or name when a type/function is defined, not when they're used)
6. Miscellaneous keywords (const/static/inline...).
7. Macros/meta (#include/#if)
Everything else is bloat.
>>110419933
>3. Control flow (if/while/return...)
>6. Miscellaneous keywords (const/static/inline...).
do you really need separate colors for those?
>5. Definitions (keyword or name when a type/function is defined, not when they're used)
isn't it clear from just the syntax/placement whether something is a definition or usage?
>>110419933
No, I only need
1. Normal text
2. Comments
3. Keywords
4. Literals.
That's it.
>Everything else is bloat.
What fucking else is there? You just described everything less of variable names.
I just saw that I implemented a triangle fill in my kode.
I don't need that at all, but I did it for terry. Thank you, Terry.
func FillTriangleI64(img draw.Image, tr Triangle, color color.Color) {
points := []Point{tr.PA, tr.PB, tr.PC}
sort.Slice(points, func(i, j int) bool {
return points[i].Y < points[j].Y
})
var x1, x2, x3, y1, y2, y3 int
x1 = points[0].X
y1 = points[0].Y
x2 = points[1].X
y2 = points[1].Y
x3 = points[2].X
y3 = points[2].Y
DrawCircle(img, points[0], 3, RGB444ToColor(0x100))
DrawCircle(img, points[1], 3, RGB444ToColor(0x010))
DrawCircle(img, points[2], 3, RGB444ToColor(0x001))
var y, xLeft, xRight, invSlopeLeft, invSlopeRight int
xLeft = (x1 << 32)
xRight = (x1 << 32)
if x3 < x2 {
invSlopeLeft = ((x3 - x1) << 32) / (y3 - y1)
invSlopeRight = ((x2 - x1) << 32) / (y2 - y1)
} else {
invSlopeRight = ((x3 - x1) << 32) / (y3 - y1)
>>110420344
Do you guys even know how to do a triangle fill???
>>110420090
>do you really need separate colors for those
Control flow keywords make code execution non-linear and conditional, they're some of the most major structural parts of the code. Other keywords are more like modifiers to something else and don't affect the overall idea of what's happening, if you removed them then only some internal details would change.
You could say function calls are the same, but syntax highlighting can't tell what it actually does, for example sizeof(x) just gets the size of a type at compile-time, it's not a branch of even code that executes.
>isn't it clear from just the syntax/placement whether something is a definition or usage?
Highlighting definitions makes it easier to glance over a file and find all the definitions. There can also be functions or types inside a function, it's useful to see when a block of code is just a definition and not code that does something by itself.
>>110420324
>What fucking else is there
Have you ever seen the average text editor syntax highlighting? Variables, types, function calls, macro calls, methods, operators, other symbols, different colors for different kinds of keywords, escape codes in strings.
has anyone tried to automate scraping google maps street views?
The API is expensive as fuck so I'd imagine they'd do a good job of locking it down
>>110420517
Idk I don't use meme languages with le heckin methods. Picrel is all I need. It's calming. It's home.
one tiny snail step at a time towards a CIA free computer.
mem and echo commands working.
Mem to dump value at an address.
Next fat12 testing stuff
>>110422546
>CIA free
Not exactly, if you're injecting Claude output into it
>>110422565
Only my terminal emulator is made by klaudia. Assembler is fully handcrafted.
Soon I will have to write the assembler in assembly anyways to get self-hosting as fast as possible
Should I just takes drugs, sit down and kode all night?
Doc said I should pause the drugs
>>110423965
Avoid weed, it makes it so much more complicated
>>110424288
>weed
uh, i never tried this beginner shit.
I am taking lisdexamfetamine if I take anything
How do you guys use AI at work without feeling depressed it's doing most of the coding work. People say that AI takes away the boring coding, but to me, that part is exciting and it's how you understand the code after you study it. There's no shortcuts for learning.
Is there a way to user AI to avoid the trap of turning my brain off? I've been feeling depressed cause it feels like it's just doing everything I did but faster, but at the same time, I cant really see nuanced mistakes cause the work well...works.
>>110424776
You get a wage to do work. It's work. Why are you so entitled? You get money and need to have fun too. There are people in Uganda starving and need to do flip burgers for McDonalds. But no, you aren't having enough fun when you get paid. This is why you even get paid. Kill yourself.
>>110424900
>it's bad to have standards and ethics and to have pride in your work
>I am mad because other people want to enjoy what they do
>>110424924
>it's bad to constantly nag about your off-topic first-world ""problems"" about being bored of having too many yatches o algo to everybody
At some point, yes.
>>110424945
I earned the privilege to have these problems, faggot.
>>110424927
>>110424950
>I want to enjoy what I do
>I want muh privileges
Then stop getting paid for it.
>>110424963
In le first world we used to be able to have the luxury to pick that. A good paying job that is enjoyable.
Looks like times are changing at the moment at least. So we gotta adjust and le anon is right, it's kinda depressing.
>inb4 muh black men from africa whataboutism
But anyways. I am drinking too much yerba mate. I have to pee hard rn
Do AFAB programmers exist?
>>110425033
all female all black?
>>110425046
Assigned female at birth
>>110425093
in that case, no not really.
#define TP template
#define kind typename
>>110425093
Isn't your mother the "assigned female" to you when you're born
>>110425033
There's this trans-looking but not trans Russian vulkan girl.
I wrote this code without using AI at all :)
from ibus import IBus
import time
from servo import Servo
ibus_in = IBus(0)
servo_X = Servo(pin_id=14)
servo_Z = Servo(pin_id=26)
servo_Y = Servo(pin_id=28)
delay=40
zdelay=125
dials= False
while True:
servo_Z.write(180)
time.sleep_ms(zdelay)
for i in range(delay):
time.sleep_ms(1)
res = ibus_in.read()
if (res[0] == 1):
if abs(IBus.normalize(res[1])) > 5 or abs(IBus.normalize(res[2])) > 5:
servo_X.write(round((IBus.normalize(res[1])+100)/1.11111))
servo_Y.write(round(((IBus.normalize(res[2])*-1)+100)/1.11111))
res = ibus_in.read()
if (res[0] == 1):
while abs(IBus.normalize(res[1])) < 5 and abs(IBus.normalize(res[2])) < 5:
servo_Z.write(90)
time.sleep_ms(5)
res = ibus_in.read()
servo_Z.write(0)
time.sleep_ms(zdelay)
for i in range(delay):
Good morning saar,
today we refactor the sd card and fat12 code to make it small as fuck.
Possibly using just a 512 byte pre allocated buffer and a few other bytes.
I could put the 512 bytes on the stack, too, but i don't want to rn
>>110429040
What's it for m9?
>>110429245
should be obvious
>You've hit your usage limit, so I stopped there.
>>110429633
No problem for me.
There is no usage limit in TempleOS. You can use it as long as you want to.
Will save around 20kB now with the new refactored code. Going from 24kB code size down to ~5kB
>>110425033
>Do AFAB programmers exist?
Why are you using troon terminology?
Are you pro-troon?
Sex is not ASSIGNED at birth, it is OBSERVED.
I made it. I successfully refactored my fat12 driver.
Can list files and their sizes now (based).
It shows that I was a crazy assembly beginner before. I gave a shit about calling conventions and saving registers on the stack kek. Fixed all of the stack frames now (based)
Learn Haskell.
Learn HolyC and/or RISC-V assembly.
just use AI lol
>>110433061
I mean you can to get some quick utilities. For example I vibe'd the picoterm like terminal in HolyC, because I rather wanted to get my assembler done and test it on real hardware, than building a terminal emulator.
But apart from that I just enjoy the process. Why would you purposely kill your own hobby?
>>110433507
his hobby is trolling /g/ though
Just a text editor for me. Just a TEXT EDITOR and some C for me. Yeah. I use a window manager, just a text editor for me, none of that gay pussy shit like IDEs or coding agents. Just a TEXT EDITOR and, add in some MAKEFILES in there will ya? Could you put the entire build system into a Makefile and not document any of the dependencies? NO FRILLS over HERE none of that OOP or memory safety like some kind of woke sissy tranny newfag.
anyone still reading SICP
>>110435286
big dick energy
>>110435286
you mean scp?
>>110433061
Someone used AI to "fix" my small project and it made up problems that didn't exist.
>>110419933
Separate colors for:
1. Normal text (identifiers and operators and so on)
2. Comments
3. Strings
4. Keywords (useful if you're typo-inclined!)
And, if you're feeling fancy:
5. Declaration names (good to use bold for that if the font supports it)
In theory you can do numbers as the other big syntax class, but that doesn't seem so necessary in practice. And a lot of IDEs go all clown-vomit over things, but that's really not needed.
Doing a script to analyze all our CI workflows at work, and figure out what the fuck is really going on. Since we've got thousands of them, I sure ain't doing it all by hand.
The script works... provided the network is really stable. But it's sensitive as hell to random network glitches (and runs for long enough to really notice them), and I've no idea where they're coming from.
>++++++++[<++++++++>-]<+++++.
----.
>++[<+++++++++>-]<+.
>>++++[<++++++++>-]<.
<----.
>>++++[<++++++++>-]<+.
>++[<++++++>-]<+.
<++++.
>>++++++++++.
I'll be codin' today fr fr 67 no cap on god
Can someone recommend a resource that'll let me quickly learn some CS theory related to langauges? I'm not a CS guy but I can write software well enough. I need to implement a recursive descent parser with a very simple set of 'rules'. My issues are all the random stuff I find online is extremely abstract and assumes I know what the formal definition of syntax, grammar, terminals, BNF, ABNF, etc. is. I have no idea what any of that shit is, I can't 'parse' (heh) any of that shit.
I need basics from a pragmatic POV without needing to burn through a 500 page textbook or have 3 CS pre-req courses on extremely abstract mathematical jargon. pls help
>>110438010
https://craftinginterpreters.com/contents.html
https://craftinginterpreters.com/parsing-expressions.html#recursive-descent-parsing
>>110438035
I love this guy's game programming patterns book. Thanks anon
Damn, keeping track of the stack frame sure is some boilerplate work in risc assembly.
Imagine doing cisc and making your life much easier. Or even using AI. Fucking plebs
>>110438390
yesterday I found a bug with listing more files than like 4.
Now I can list over 100 files EZ.
Still have some timeout issues on initialization sometimes. I am not sure if this is my SPI driver (probably) or the cheap chink 128MB sd cards (maybe).
I suspect the former because GNU has no problem reading them ever.
Getting a lil distracted with the sd card rn, but it has to be done anyways at some point
>>110438745
back at the command line now.
H3h, I thought the prompt was stuck, but it just didn't print correctly in the beginning. All fine :^)
Just backspace not working as expected.
For the newfigs:
this is me assembling risc-v assembly with my own fucking assembler (written in HolyC) and uploading it with xmodem via rs232 to my own fucking SoC and then executing it.
self hosted OS isn't that far away anymore. At least I can see it 40 km away
>>110439326
This is the board.
Technically it's not my own fucking SoC, because I use the neorv32 CPU, but at least I wired it up myself. Own risc-v cpu coming soon, too
I just upgraded my Famicom to 8kB of main memory.
>>110439383
What are you going to do with all the memory now?
>>110369197
started learning just few days ago... i made this simple app that plays rain sound something like blanket but only with rain but i wanted stupid audio controls so i added pump and etc... i want to implement rain coins so after 30 seconds you get like one rain coin and then be able to play simple automat and win more to unlock next sound. Im not planning to release this or anything it's just for fun...
>>110441177
ok that's based and all and you got good repeating digits.
But who the hell puts + on the left and - on the right? Holy fucking shit. That triggers me
>>110441345
Thanks, will switch it up later i just put it up there for testing this isn't how it's going to look probably if i find some better documentation around VBA.
>>110442321
Don't worry. I was just shitposting.
If it's just for you anyways, then just have fun and enjoy the process. no homo.
Maybe this here is my first and last nice post this year
>>110439803
Good question.
Here's a shitty toy program I just made to kill some time.
#include <pthread.h>
#include <stdio.h>
#include <stdlib.h>
int primesFound = 0;
int primes[10] = { 0 };
pthread_mutex_t lock = PTHREAD_MUTEX_INITIALIZER;
void *primeWatcher(void *ptr) {
char workTodo = 1;
int previous = 0;
while (workTodo) {
pthread_mutex_lock(&lock);
if (primesFound != previous) {
printf("Finding prime number %d\n", primesFound + 1);
previous = primesFound;
if (primesFound >= 10) {
workTodo = 0;
}
}
pthread_mutex_unlock(&lock);
}
}
void *primeFinder(void *start) {
int num;
int divisor;
char stillPrime = 1;
num = *((int *)start);
while (primesFound < 10) { // search for prime numbers
>>110445377
What did some time ever do to you
>>110445466
It won't be doing anything to me now.
>CLOCK_TAI
someone please tell me why this exists? I thought date/time shit was retarded enough as is but every time I dig into some function or header I discover new levels of autism
>>110369197
I wish I could talk about this stuff without doxing myself.
Can I get a subscriber PLEASE?
https://youtube.com/live/I7H1iadFfWw/
>>110447084
The person on screen is redundant to the stream.
>>110447129
That's not fair, today I didn't use Gemini at all
>>110419806
Marry her for the memes
Coins launched here are paired with $4CHAN on pump.fun and 100% of their creator fees are burned. A coin listed under a thread is not endorsed by the thread’s posters or by 4chan.
No coins yet. Be the first: [Launch a Coin From This Thread]