[a / b / c / d / e / f / g / gif / h / hr / k / m / o / p / r / s / t / u / v / vg / vm / vmg / vr / vrpg / vst / w / wg] [i / ic] [r9k / s4s / vip / qa] [cm / hm / lgbt / y] [3 / aco / adv / an / bant / biz / cgl / ck / co / diy / fa / fit / gd / hc / his / int / jp / lit / mlp / mu / n / news / out / po / pol / pw / qst / sci / soc / sp / tg / toy / trv / tv / vp / vt / wsg / wsr / x / xs] [Settings] [Search] [Mobile] [Home]
Board
Settings Mobile Home
/g/ - Technology


Thread archived.
You cannot reply anymore.


[Advertise on 4chan]


 
console.log("What are you working on, g?");
>>
>>100159394
I used to be working on a backup script for windows. Does anybody know how to restore data to users that have been created but not yet initialized. I cannot just move the folder back to
c:\users
since that would mean windows will create other one instead.
>>
File: Beef256-2555236154.png (67 KB, 256x251)
67 KB
67 KB PNG
>>100159394
Porting my game engine from C++ to Beef.
It will probably take more than three months.
>>
>>100159460
If I were doing this on Linux I'd have a restore user who's home directory was on the same filesystem as the other users and restore the data to the restor usere's directory. Then once the user is created I'd set the folder permissions to be owned by the user and writable by the back group, move the directory to their home folder (this is a single atomic operation) then set the folder to be owned by the user's group as well.
This way the home folder is always available for temp files etc.
>>
>>100159394
What happened to the maidposter?
>>
>>100159551
Yeah but I'm writing this script on Windows.
And it's like a patient rejecting a new liver. It will not accept the folder to be used even if the user has the proper rights set to that folder. it will create a new folder with a dot and the suffix being the computer name. which it doesn't do if you don't move the folder back to c:\users
>>
>>100159559
Died of ligma.
>>
>>100159460
delete the user and then recreate them with the "make home dir" option (linux' useradd has it, windows might too) and just move stuff over
>>
>>100159522
and it'll very likely perform worse as well

if you're just doing it for the memes you should port it to zig so i can rightfully call you a zigger.
>>
>manager tells the team that I will lead the software development
>tell the team to their tasks
>they start doing anything but the thing I told them to do
I HATE PROGRAMMING IN A TEAM
I HATE PROGRAMMING IN A TEAM
I HATE PROGRAMMING IN A TEAM
>>
while nigger:
society.collapse()
>>
>>100159394
PREVIOUS THREAD NIGGER
>>100141763
>>100141763
>>100141763
>>
>>100159636
try acting like a leader instead of whining on dpg
>>
>>100159666
lol no, I started looking for a job in smaller company where I can do my work alone.
>>
fixed audio track selection for my youtube client
now it selects the default track instead of the first available one (which sometimes can be dubs in other languages for some videos)
>>
>laid off from dev job after 4 years
>have bad depressive episode after failing a bunch of interviewd and give up for months
>1 year post layoff
>can't get interviews for non development jobs
>can't make myself code unless I'm getting paid for it that very second so I can't pass interviews
Is there any way to find my motivation again? I never really liked coding but now it feels like it's the only option I have
>>
>>100159690
you'd rather demote yourself back to a code monkey, than teach yourself some social skills and how to act like leader?
Team leads and managers are the sort of roles where one can end up making the high end of six figures in software development. You're wasting this opportunity.

>inb4 i dont care about money
>inb4 i dont care about career
you will regret thinking this when you're older, this is a classic mistake young people make. Thinking they're above money and career success because muh slice of life anime and powerfantasy or some bullshit.
>>
>>100159794
Start a new side project
>>
>>100159796
It's just not meant to be for some people.
>>
>>100159636
based. being "lead" and having no authority to fire people at will is unironically why so many projects are such absolute failures.
>>
>>100160015
I'm not going to babysit retards who can't follow orders.
>>
>>100159666
you can't act like a leader. the roles are bait to set you up when it doesn't work.
>>
>>100159796
retards like this is why companies are bloated garbage that can't get basic projects done. I kek thinking of the billions being wasted where I work while the upper echelons of the hierarchy continue to bloatmaxx endlessly. 4 years overdue and the project I work on is constantly underfunded with no technical staff capable of executing. Maybe hiring more worthless PMs, Execs, tech "leads" and shit will make all the contractor effort magically materialize. who knows.

in other words, I hope Bayer succeeds firing all of their worthess middle manager cuckolds and give power back to wagies to actually self-organize and do their fucking job.
>>
>>100159796
Typical boomer speak. No wonder your generation had the highest divorce rates.
>>
>>100160398
i fail to see how that has anything to do with what im saying.
You can rightfully hate middle management if you want, but its the truth that they make the big bucks. If you were invited to be in that role but dont take it seriously you are wasting an opportunity.

>>100160427
>"you should accept your promotion" is le bad
do what you want. Go work at starbucks for 4 hours a day at 15$ im sure you'll be winning at life with all that freetime you have over managers who earn 10 hours a day and make 500k a month.
>>
>>100160520
>earn
work*
>>
>>100160520
>but its the truth that they make the big bucks
not really. it depends. Some HR idiot told me I would be the most overpaid tech staff on the "team" and I told her to fix the offer or fuck off. Later get a call back and they made it so. You just have to not be shit at your job and demand pay.

if companies want to continue to fail and overpay their worthless staff, that's a them problem, but it's not a *me* problem.
>>
>>100160520
>le hamsterwheel is le good
Believe it or not, but human beings don't need gold pieces in their cacao to survive. Regular milk does the trick just fine.
>>
>>100160568
> I told her to fix the offer or fuck off. Later get a call back and they made it so.
then you work at a good company but many companies are too retarded to do that.
They literally think managers are 90% responsible for the success of a department or team, while code monkeys are completely replaceable.
If you ask for a large promotion they'll just deny you because they think you're replaceable with some college student, even if you're actually doing the vast majority of the teams work. Meanwhile if a manager / team lead asks for a large promotion they'll actually think their entire tech department will get fucked for months if they dont grant it and they leave, so they almost always do.

I literally agree with you companies are retarded and thats why middle management gets paid so well.

>>100160592
>muh slice of life anime and powerfantasy or some bullshit
>>
>>100160634
>muh slice of life anime and powerfantasy or some bullshit
The wagie cope is real.
>>
>>100159394
im writing a Krita plugin that works as a front-end for ComfyUI. it's almost ready, probably mostly usable by the end of this week.
>>
>func DrawMask(dst Image, r image.Rectangle, src image.Image, sp image.Point, mask image.Image, mp image.Point, op Op)
>DrawMask aligns r.Min in dst with sp in src and mp in mask and then replaces the rectangle r in dst with the result of a Porter-Duff composition. A nil mask is treated as opaque.

Am I supposed to understand this gibberish?
>>
>reply in interesting thread
>go to bed
>wake up
>anon replied, but thread died
Fucking hell, why don't threads last on /g/?
>>
>>100161167
What don't you understand about it?
>>
File: 1636188000762.jpg (349 KB, 1378x1008)
349 KB
349 KB JPG
>>100161168
Pajeets killing the Apple out of tech world, mostly.
>>
>>100161181
>align r.Min in dst with sp in src and mp in mask
this sentence
>>
>>100161181
nvm i think i get it
>>
>>100161316
Min is a member of the Image.Rectangle r, perhaps its the top left point or something. that rectangle is placed on top of dst, then src is placed on dst such that sp and r.Min line up, then mask is placed such that mp and r.Min line up.
>>
>>100161224
>good morning sir! killed my thread
Great, now I have another reason to hate pajeets.

Side note since you brought them up: I've spot checked solutions on HackerRank and my suspicion is that 99% of pajeets simply copy/paste solutions from pajeet "HackerRank solution!" web sites to get their badges/certification, even though HR ToS explicitly forbids this. I would have to do a deeper analysis to get exact numbers, but I don't want to scrape the site in any way which would run afoul of their ToS or the law. (Even though those pajeet sites are doing just that to get solutions.) I guess this shouldn't surprise me, but it's still just jaw dropping to see in action. Pajeets really are shit with zero ethics and zero actual interest in learning about computers.
>>
I stopped caring about type safety, I just use void pointers raw.
void *DArrayBinarySearch(DArray *darray, const void *target, int (*CompareCallback)(const void*, const void*))
{
if (darray->dirty)
return NULL;

size_t left = 0;
size_t right = darray->size - 1;
while (left <= right)
{
size_t mid = left + (right - left) / 2;
void *index = darray->data[mid];

int cmp = CompareCallback(index, target);
if (cmp == 0)
{
return index;
}
else if (cmp < 0)
{
left = mid + 1;
}
else
{
right = mid - 1;
}

}
return NULL;
}
>>
>>100161458
>void pointers
be a man and use unsigned long
>>
>>100161458
Absolutely based, type safety is for pussies.
>>
Teaching myself Ocaml. Been going down a functional programming rabbit hole.
>>
>>100161553
What's a man to do with 32 bits on a 64 bit platform?
>>
>>100161609
go to sleep old fart, ints are not 2 bytes anymore.
>>
32 bits are slower and more cumbersome to process than 64 bits on a 64-bit processor.
>>
How do I make ui look good? Mine is alright but still looks like something a student would make, which won't help me get a job.
>>
>>100161666
Good.
>>
>>100161623
He said something about unsigned longs in relation to pointers, which makes no sense.
On LLP64 platforms, long is just 32 bits and on I have no idea what model CHERI uses, but pointers are even more special there.
>>
>>100161224
this is not posted enough
i have had enough of jeetdroid users /g/aslighting claiming it is the opposite
>>
>>100161733
all my life i have known longs as 64bits, pointers arent real
>>
>>100161563
Yeah, especially in C. I used to use macros before and it was ugly and time consuming.
>>
File: 1712193112775117.png (80 KB, 266x291)
80 KB
80 KB PNG
I want to like Idris, but the automatic currying thing seriously hurts the readability of the language. Seriously, Haskell and Ocaml have this problem too. I've been writing code in these languages for years, but I still can't figure out the Arity of a function at a glance. Does it take multiple parameters? Does it return multiple parameters? If any of the parameters are higher order functions (god forbid those higher order functions also have higher order function parameters) then the whole thing becomes a nightmare. Why the fuck does the ML-family keep using this antifeature? Partial application isn't even a good idea. I thought it was cool when I started out learning Haskell, and certainly very powerful, until I had to unravel a huge network of partially-applied functions to find out where a bug was coming from. Well, it was a cascade of operator precedence issues that cropped up for reasons I still don't understand because I gave up trying to map out where shit was going wrong. Ended up having to rewrite the entire codebase from scratch because it was just that fucking bad.
>>
>>100161956
>Why the fuck does the ML-family keep using this antifeature?
Same reason Batman villains return all the time: no one murders the ones responsible.
>>
>>100161458
>>100161898
who ever told you to care about type safety if you're writing c, in the first place?
as you say its a mess to deal with due to the lack of features in the language. Pretty much everyone always uses void* in c and have always done that.

If, however, you are using an actual good language like c++ then dealing with type safety is trivial and almost as easy as just doing void*, but of course without the segfualts.
>>
>>100162107
>an actual good language like c++
Lol
Lmao
>>
>>100162107
segfaults are a non issue, they are trivial to fix with gdb and valgrind.
>>
>>100162250
Nocoders are deathly afraid of segfaults though.
>>
>>100161956
get good scrub
>>
>>100161956
The lambdas take 1 argument exactly and produce 1 result exactly.
If you want arity in your functions, uncurry them.
Write (a, b, c) -> d to have a function of arity 3 and one result.
(a, b) -> (d, e, f) to have 2 inputs and 3 results.
Or package your inputs and results in a more expressive datatype, if you don't like tuples.
Partial application is key for reusability and lazy evaluation.
>>
>>100162250
we use address sanitizer now chud
>>
File: sicp.png (44 KB, 2048x2048)
44 KB
44 KB PNG
I have all the time in the world at my job (I do basically nothing). What if I made a basic utility library and a gui toolkit. And then used that toolkit to make a desktop environment. Then a Linux distro based on that DE.
Then a tech startup and a kernel with a translation layer with Linux and WINE for software compatibility. Then started selling computers with that OS to compete with Microsoft and Apple.

What does /g/ think? Is this even possible or a waste of time? The purpose would be to make a fast and secure desktop OS.
>>
>>100162313
Who cares? They only reveal the most basic errors.
>>
>>100162367
>what if I did Xorg 3.0
So how's your driver support? Do you know the difference between explicit and implicit locking? Do you know what a shadow framebuffer is? And most important of all: where did X11 and Wayland fuck up?
>>
>>100162297
>Partial application is key for [...] lazy evaluation
It isn't though, that's just a consequence of the execution model. Graph reduction needs to know the full arity of a function to work with it. The STGM doesn't see the currying, all of these functions end up as vertices with multiple edges (an edge in a GRM is an input or output)
>>
>>100159394
> someone shills Beef on /g/
> its c++ with modules and sane syntax !
> sounds nice
> git clone
> spend 8 fucking hours fixing shitty Windows dev mistakes
> still doesn't compile
> llvm build fucking fails because they missed some headers
I learned nothing and am disappointed. My disgust for bash/cmake has only increased my disgust for google even more so for falling to provide any good solutions to my queries. It sounded so fucking good I just wanted cpp with tagged unions and nice tuples....
>>
>>100162439
I'll look into that. For now I'm just thinking of some basic utility libraries and a GUI toolkit that can be used with some existing display server.
>>
>>100162553
Alright, then I got another question:
How much do you care about backwards compatibility? Y'know, just in case you realize that your existing infrastructure is trash and needs to be rewritten from scratch.

>>100162501
Is this the new "all I wanted was C with templates"?
>>
>>100159522
you are, a retard
>>
>>100162501
>cpp with tagged unions
https://github.com/Hirrolot/datatype99
>>
>>100162501
>tagged unions
Inheritance
>>
>>100162638
>I want a race car
>Um sweaty, have you tried flapping your hands really fast to fly around like a bird?
>>
>>100162583
Not too much. Rewrites need to happen and I expect the project to stay niche for a while so even if I break compatibility it probably wouldn't cause too much damage anyway. I can also make an effort to submit pull requests to update software using the libraries to bring it up to date.
>>
>>100162663
Have you?
>>
File: 1695574660843151.png (341 KB, 1137x860)
341 KB
341 KB PNG
there's no inheritance without inheritance tax
>>
>>100162726
>Not too much
In that case: knock yourself out, but be prepared to throw it all away once you've acquired sufficient domain knowledge.
>>
>>100162732
your honor, i plead the 5th
>>
what's wrong with POSIX shell?
>>
>>100162791
it's retarded and doesn't do a lot of things.
windows has it worse though.
>>
>>100162791
>cmake
>autotools
>ninja
holy fucking shit how about you use none of those

>m-my build times!
maybe your codebase is architected like complete fucking dogshit. have you considered that?
>>
>>100162786
Technically the correct phrase would be
>I invoke my right to avoid self-incrimination.
>>
>>100162613
Thanks for the lib I will look into it. beef looked simply clean I wanted to get rid of headers and cmake also getting tuples without additional syntax would have been nice..
Guess I will wait another decade before he can be assed to make a linux build.
>>
>>
>>100162501
Don't bring CMake into this beef nonsense, thank you very much.
>>
>>100163076
Finally, a programming language made for crackers.
>>
what's the recommened way to start developing android apps as a beginner? kotlin and android studio?
>>
File: 1693938127408479.png (277 KB, 1441x961)
277 KB
277 KB PNG
trying to learn postgres in my spare time. thoughts on this design?
>>
>>100163076
>garbage collector
Imagine putting that in your advertisement.
>>
>>100162367
>What if I made a basic utility library and a gui
Cool.
>make a desktop environment.
Now you're in the shitty world that is matters of taste. Text labels or just icons. Click to select or click to activate. Labeled sliders for keyboard repeat rate or blank. Default theme light or bad.
All the shit that people argue about, you pour it over your own head.
>Then a Linux distro based on that
Are you talking about becoming a community spin on Ubuntu, Arch, etc., or actually being the next contender on DistroWatch?
>tech startup and a kernel
You're leaving Linux behind to compete with it and BSD and ... whatever else might be out there.
>with Linux and WINE for software compatibility
Linux isn't compatible with itself thanks to shit like SystemD versus Not yet SystemD, and WINE stands for Wine Is Not Enough when it comes to shit that people actually care about.
>selling computers with that OS to compete
Are you going to get businesses to care about your platform?
Normies don't give a fuck, they've got the Facebook and the X on their phones.
Desktop means two things: high performance gaming (which entails that you must support invasive anti-cheat) and actual business work kinds of shit. And last I heard, Linux still doesn't have an AutoCAD killer or WINE support for any meaningful CAD.

>Is this even possible
Anything's possible.

>a waste of time?
A hell of a gamble of time.

>The purpose would be to make a fast and secure desktop OS.
You said you wanted compatibility, but insecure-system software will be insecure.

I vote do Linux From Scratch and learn what it takes. Make fast+secure your watchword, and try to prototype something.
If you can get that far, you'll know what to do next.
Good luck.
>>
>>100162501
> someone shills Beef on /g/
>no wiki page
>find a draft for one
>body text just ends mid sentence
>that sentence is, "While Beef is not memory safe, "
I'm not inspired.
>>
>>100163832
picked up
>>
>>100163035
>I wanted to get rid of headers and cmake
Why do you think that you need cmake?
>>
>>100163866
are you a gnome dev?
>>
>>100163605
it's talking about the GC supporting parallelism, not having GC in the first place
>>
>>100163879
No. Now answer my question.
>>
OHHH ITS COMPILING PRAISE BE DOCKER
seriously what a shitshow just because cmake couldn't pickup llvm-13
>>
>>100163832
>>no wiki page
>>find a draft for one
link? I can't find it
>>
>>100163976
never mind
https://en.wikipedia.org/wiki/Draft:Beef_(programming_language)
>>
>>100163911
That only makes it worse:
>we could've just gotten rid of it, but we decided to DOUBLE DOWN!
>>
>>100163552
- Why are Anime and Manga separate but with identical (as far as I can see) columns? Likewise with the Seen/Plan/Favourite tables where the split is forced by the two main tables. Some people might argue that this is the most pure way to do the schema, but my mind sees double the work and code. I would likely have one set and just have a type field in the main table, which would also make it easy to add even more types later. If type is an int with a typename table that actually describes it then joins will be faster, but you also need at least one join to get the string name/description.

- Genres and Tag? You're already storing the string, those tables just store it again. Why? genre/tag_name should be id to those tables which then store the string, eliminating duplicate string storage rather than amplifying it.

- Looking at the smaller tables: I know that officially you can do a PK on a FK + another field, and some would argue that if you can you should. But when I do a db I always have a dedicated PK (bigserial) field for a table so that no matter what I change later there's one ID that clearly identifies each record in a table. This may not matter for you, but in complex operations when I haven't had that I find that I wish I did.

- I don't see an Active boolean field. Active lets you keep records around for a while after a delete (just mark it inactive). May not matter for you, but in business databases it's always a good idea to deactivate and delete at a later date. I've had clients who never actually delete, but at most end up purging inactive records to a separate schema, i.e. for legal reasons they have to keep it. It depends on what you want but if this is practice in the hope of future work, you might want to go ahead and do that because it will make you think about it in whatever front end client you write.

Nothing else stands out to me at the moment, but I'm also on break and can't look at it for long.
>>
So which one?
init / deinit
init / uninit
init / reset
init / teardown
new / free
new / delete
>>
>>100164039
init / outit
>>
>>100164026
>separate manga and anime are double the code and double the work
You're thinking like it's Java with OOP and you have abstract classes with abstract methods.
Tables have no methods. There is no double work. If you want everything then instead of a double join you do a union and that's it.
Think in terms of entities and relations, achieve the best normal form you can, and you will be happy. You won't need a billion triggers and a billion constraints to maintain consistency.
>inb4 muh nosql gigabase
Only do this if you don't give a shit about your data.
>>
File: file.png (148 KB, 906x422)
148 KB
148 KB PNG
now how the fuck can I get a static build going? I don't want to mess around with. LD_LIBRARY_PATH had enough of that shitshow already.
>>
File: 1687892163119837.jpg (133 KB, 1125x632)
133 KB
133 KB JPG
>>100164026
>Why are Anime and Manga separate but with identical (as far as I can see) columns?
originally i had a "media" table with a "type" enum, but another anon recommended i separate them. he said type enums introduce redundancy. i dont plan on adding more media types in the future unless anilist does, so i thought keeping them separate wouldnt be that bad.
>Genres and Tag? You're already storing the string, those tables just store it again. Why?
anilist doesnt provide a "genre" object, genres are just a list of strings on the anime/manga, so there's no id. i didnt want to generate an id for genres either since i would still have to check if the name is unique in the table every time i want to add to it anyway. id just seemed like a pointless field to me but if storing duplicate strings is really bad i can change it. tags actually are an object though so i should probably redo those tables.

thanks for the reply btw
>>
>>100164026
>>100164375
and btw anime/manga do have one unique field each: "episodes" or "volumes". but they're both ints, so i thought i could just do something like "episodes as count" and "volumes as count" in a union if i ever wanted everything.
>>
>>100164371
By not using -l and by providing paths to the libraries as if they're object files.
>>
>>100162590
No, you are.
You also lack perspective in that matter.
>>
>>100159394
I'm stuck in an endless loop of restarting and restructuring. I created XXX_April today and it's the 11th XXX_something file on my computer
>>
>>100159624
Well, who knows, right? It will probably perform a little bit worse. Because the C++ compilers are state of the art when it comes to optimizations. But when it comes to features, beef is a lot better than C++, at least for game development.
>>
File: g++_aint_better.png (7 KB, 988x128)
7 KB
7 KB PNG
>>100164807
>Because the C++ compilers are state of the art when it comes to optimizations.
Which isn't a very high bar to meet, let's be honest.
>>
>>100164352
>>separate manga and anime are double the code and double the work
>You're thinking like it's Java with OOP and you have abstract classes with abstract methods.
So there's never going to be a client of any kind? All data will be entered/edited as insert and update statements in a SQL query tool? I mean...kinda based in a Terry Davis way, but otherwise....

>Think in terms of entities and relations, achieve the best normal form you can, and you will be happy.
I would never be happy doubling the number of tables because of a difference like this. That's not normalized to me at all, that's like having separate tables for blondes and brunettes instead of a hair_color field. There may not be methods but schema changes are doubled because this bleeds into other tables.

>>100164375
>originally i had a "media" table with a "type" enum, but another anon recommended i separate them. he said type enums introduce redundancy.
To me this introduces redundancy, but an anon above disagrees.

>anilist doesnt provide a "genre" object, genres are just a list of strings on the anime/manga, so there's no id. i didnt want to generate an id for genres either since i would still have to check if the name is unique in the table every time i want to add to it anyway.
Correct me if wrong but genre/tag won't always be unique, will they? If they're going to be shared then that's duplication/redundancy of shared strings. You don't need an ID provided to you, you can just bigserial an ID field.

>but if storing duplicate strings is really bad i can change it.
I'd be lying if I said I never did it because I was lazy/annoyed/pressed for time, but it is a bad idea. Duplication of shared data and it introduces the possibility of a misspelling causing records to not show up in a select when they should.

>thanks for the reply btw
You're welcome.
>>
File: 1708995971642346.gif (546 KB, 220x220)
546 KB
546 KB GIF
>>100164002
>getting rid of GC in an SML implementation
>>
File: file.png (870 B, 28x28)
870 B
870 B PNG
How do I convince the recruiter I know Golang?
>>
>>100165342
that depends, do you know golang?
>>
>>100165355
I know Java.
>>
>>100165360
its so fucking over for you dude
>>
>>100159394
C, Rust ,Haskell!
>>
>>100165360
then just write java but only make 50% of things a class, swap = for :=, swap your type and variable name order, and tell them how much you love the concurrency support built into the lang
>>
>>100165396
Actually, thinking I'm at a disadvantage because I know Java and want to jump into Go is pretty hilarious. Java's like the boot camp of programming languages—gets you in shape with all its rules and complexity. So, picking up Go? It's going to be a breeze in comparison. It's not about the language, dude, it's about the skills. Saying it's "so over for me" just shows you don't get it. Learning new languages is part of the game, and honestly, it sounds like you're the one who's missing out. So, no, far from being "over," I'm just getting started.
>>
>>100165420
>swap = for :=, swap your type and variable name order
Why did the zoomers start doing these things?
>>
>>100165452
But actually, why?
>>
>>100165452
Pascal did it first so that people wouldn't confuse the assignment (=) and comparison (==) operators, because apparently code such as
if(x = 3)

used to be a thing.
>>
>>100165452
Other way around
:= was first
>>
>>100165491
How is
text := "Hello!"
better than
text = "Hello!"
>>
>>100165442
It has nothing to do with whether or not you can pick up the language. I should certainly fucking hope you can pick up a language other than Java. The problem is by the time you've unlearned all the garbage habits you've built up writing Java, and you've got enough experience to pass as knowing Go, the recruiter is going to have moved on/found someone else. Don't worry, keep at it for another 20 years and eventually you'll be able to pick up a new language in the span of a day or two. You're not there yet, though.
>>
>>100165521
Then we've evolved not to need it. Why bring it back? Shift and a key to clutter crap up.

>>100165491
>apparently code such as used to be a thing.
It's rarely necessary, but I've done it a few times. It's about as sensible as ++ or -- in a line doing something else. It's a tool that belongs in the tool box, but you never want to need to use it.
>>
>>100165533
It wasn't that it was better, but that it wasn't much worse.
>>
>>100163552
Add a record added_on and updated_on columns
>>
>>100165452
Go got it from Limbo which was made in the 90s
>>
>>100165548

Your assumption that I'll need decades to adapt is not only laughably pessimistic but also grossly underestimates the plasticity of a skilled developer's brain. It's not about unlearning; it's about adding more tools to one's repertoire. The real problem here isn't about transitioning from Java to Go. It's about your limited understanding of how skill acquisition works in the tech world. Recruiters aren't just looking for someone who's stuck with one language their whole life. They're looking for people who can adapt, evolve, and embrace new challenges. So, while you sit there, smug in your belief that you've got it all figured out, I'll be expanding my skill set, securing those positions, and proving yet again that adaptability trumps stagnation. Keep watching, you might learn something.
>>
>>100165533
Originally
:= was to set a binding / declare an init value
= was to mutate
>>
>>100165573
Bro who cares, Golang is from 2009, 9 years after C#, why is it still so outdated?
>>
File: 1655789919012.png (131 KB, 339x332)
131 KB
131 KB PNG
>>100165567
Wrong post, mate.
>>
My uncle sent me this codingchallenge website, but I'm sure there is something better, any recs?
https://codingchallenges.fyi/challenges/intro/
>>
File: dump.png (89 KB, 1894x989)
89 KB
89 KB PNG
>>100165624
Windows registry dumper.
>>
>>100165632
win32 deleter when?
>>
>>100165639
https://gparted.org/
>>
>>100165664
Did you make that?
>>
>>100165664
Here I sit, broken hearted
Picked wrong drive in gparted
>>
>>100165691
You caught me, I'm GedakC.
>>
File: aVMXR6d_700b.jpg (40 KB, 640x630)
40 KB
40 KB JPG
>>100164039
putin / putout
>>
>>100165521
pascal was after c
>>
>>100165759
no it wasn't lol
>>
>>100159522
What problems did you run into with C++ that beef solves?
>>
>>100165828
garbage collection
>>
>>100165759
Retard
>>
>>100165839
Check out D then
It’s even better than Beef and C++
>>
>>100165014
>So there's never going to be a client of any kind? All data will be entered/edited as insert and update statements in a SQL query tool?
yeah pretty much. im planning to use python and psycopg. i thought about adding some kind of frontend/UI, but i dont really see the point. im probably not gonna interact with the database directly very much. the script that syncs the data is probably just gonna run on a time interval. i may want to add some kind of client in the future if i want to work on my UX skills, but even if i do that im sure i can find an easy way to handle all the different tables.
>>100165549
thanks
>>
File: equally_tiring.png (1.99 MB, 1920x1080)
1.99 MB
1.99 MB PNG
>>100165839
I don't understand why people just don't use arenas - *especially* if it's an engine you'd think people cared about memory management.
>>
>>100166082
Because arenas still have to be used and thought about. It’s very high level MM, but still MM. the entire point of GC is NEVER having to worry about memory at all.
Programming needs to get away from MMM altogether.
We let computers do our maths, so we should also let them reason about the memory so we only need to focus on the problem.
>>
>>100166117
>It’s very high level MM, but still MM.
Quite the contrary, it's a low-level approach. You know exactly what chunks of memory you've allocated and where your data is to be stored, which in turn allows you to unify lifetimes even further (one arena for every even frame, one arena for every odd frame). In a game development setting you absolutely want to manage your own memory.

>the entire point of GC is NEVER having to worry about memory at all.
What the hell are you doing game development for, then?!
>>
>>100161956
If you need FP and arity, you want prolog.
Your choices are Erlang or Mercury
>>
>>100166117
Isn't that essentially what GPT and friends are supposed to eventually do? You just tell them what you want and they shit it out.
>>
>>100166168
>>100161956
How do you guys get to a point where you touch shit like Haskell, Ocaml, etc? Me and my friends in the field are all working with normal stuff like python, c++, c#, etc.
>>
>>100166117
Also:
>so we only need to focus on the problem
Utter bullshit. Memory is part of the problem, and denying that is denying reality.
https://www.rfleury.com/p/untangling-lifetimes-the-arena-allocator
>>
>>100166117
>the entire point of GC is NEVER having to worry about memory at all.
That's not really true, even with GC there are avoidable memory pitfalls you should be mindful of. It just makes it easier for idiots to write programs that don't crash.
>>
>>100166117
The issue is guidance. For normal computing, garbage collection is fine. But things with performance considerations and performance issues like games will get pelted with reeeees if it hitches to collect garbage right on the frame that someone needed to boom a headshot.

Makes me wonder, is there not a garbage collector that you can tell it something like, "you have 1ms, do what you can without taking longer than that" so you can GC when the FPS is solid and let it build up in performance critical moments, without having to totally do memory manually?
>>
>>100166167
I meant high level in context to user-space burden.
Malloc/free are low level and burden the user with a lot of responsibilities.
Arenas (assuming you’re using a premade) are generally just werks and basically GC for people who can’t admit they want GC.
>why do you want to make games instead of playing with bytes
Is this an actual question?
There’s a false equivalence for game dev and MMM. Which got perpetuated because of boehm trash polluting the perception of GC
>>100166178
Only because of Currently insufficient tech and programmers refusing to accept that memory is no different than maths in terms of automation needs.
>>100166207
Assumes a hypothetical best GC that solves everything for you
>>
>>100166235
>Assumes a hypothetical best GC that solves everything for you
That's not how programming works. A well-designed GC can have excellent performance characteristics, especially compared to malloc/free, but there's always a penalty. TANSTAAFL.
Unity, for example, uses C#, which has GC, which generally works fine, but still has potential issues: https://docs.unity3d.com/Manual/performance-garbage-collection-best-practices.html
>>
>>100166221
>"you have 1ms, do what you can without taking longer than that"
Unless you're developing without kernel between you and the hardware that's highly improbable. Code can't know when it's being preempted, or when something is taking longer than it's supposed to; it can't really say "I can free these couple chunks, but if I take one more I'm over the threshold".

Which is yet another reason why arenas are so good - since you've decided what goes where you can also decide to delete it all by, let's say, resetting the end index back to the beginning.

>>100166235
>Malloc/free are low level
Lol no, they're not. NtAllocateVirtualMemory is low-level. mmap is low-level. Hugepages are low-level. malloc is generic slop without much granularity (except the allocation size). What is true is that they burden the user with responsibilities, but that's not because they're low-level, but because they're managing their own state so that they can avoid mode switches. With arenas you can implement a dirt-simple stack that doesn't need state other than the amount of memory already written, and as stated above setting that variable to 0 frees the arena without mode switch or locks.
>>
>>100166291
C# is garbage and not indicative of a model GC.
You need actors, inherent concurrency, message passing and minimal to no coordination in your GC.
The JVM people eventually figured this out.
>>
>>100159394
>cursed legacy code made by a dumb company
>offloaded to us because the retards couldn't maintain it
>critical
>cursed demonic god-forsaken docker setup
>wasted hours just to mount a volume to TRY and make a development version, where I don't need to rebuild to see changes
>first bug handed to me is IN FUCKING PEE DEE EFES
>One of the *critical* reports generated to the user has a one of the text-field overlapping
>find -type f -name "filetype-of-the-report-generator" exec sed s/overlappingstring/HELPME/g {} +
>grep . 'overlapinpingstring' > zero results
>rebuild images
>PDF IS THE SAME
>>
>>100166385
>legacy
>docker
uhh anon
>>
>>100166385
It's thanks to them that you get money you dumbass, it's like complaining people are hungry as a food salesman.
>>
>>100166454
early python 2 code, we had to split the cursed codebase among several servers in a cursed docker thing for it to be able to handle the new demand. When the tards had it they ran it as a monolith django app
>>
>>100166363
>The JVM people eventually figured this out.
You mean Google with GGC.
>>
>>100166485
The docker setup is cursed because we made it that way, its just the cherry on top of it all. It WORKS, but its annoying. It's going to be fun to change from centos 7 in two months.
>>
>>100166489
No, I mean the MVM extension paper where they discover message passing vs trying to schedule sharing on multiple processes.
And then the same with “Why do computers stop and what can be done about it”.
>>
>>100166553
Then why doesn't C# use it?
>>
>>100166569
Because it’s a garbage language and M$ at the time had no talent.
Modern M$ Research is quite good though. Sylvan Clebsch is doing great work on progressing GC.
>>
Any Magit-sisters here? How do I make magit show the real date of a commit in the log instead of a relative date?
>>
Use plain git like a real girl(woman)
>>
>>100165014
>I would never be happy doubling the number of tables because of a difference like this. That's not normalized to me at all, that's like having separate tables for blondes and brunettes instead of a hair_color field. There may not be methods but schema changes are doubled because this bleeds into other tables.
No. Because anime and manga are different. Just because they share a lot of media properties it doesn't mean they don't have different attributes. You don't put books, tv shows, and movies, all in the same table.
Or another example: you have people with name and address, landmarks with name and address, pets with name and address, and businesses with name and address. Do you put all of it in a ThingOfThePlanet table with a big enum field? No.
Blondes and brunettes don't merit separate tables. They could though, if you presented me a model of reality where it was imperative to model them separately for whatever reason.
And also, you wouldn't do a hair_color enum field. Doing that opens the table to null hair colors, empty hair colors, brunette hair color, blonde hair color, kinda brunette hair color, blonde with blue striped hair color, etc. Unless you add constraints to enforce consistency. Or maybe you do not care and want to treat hair color as an address, just a string, but then there would be no way this attribute could be misintrepreted as a possible entity, thus deserving a table.

>>100163552
What is media_id in say, Media Studio and the others? anime_id or manga_id? If I grabbed all the media from the studio with studio_id 1, how do I know it's anime with anime_id 1 or manga with manga_id 1?
>>
>>100166705
Or just use plastic like anyone with a brain.
>>
>>100166604
https://magit.vc/manual/magit/Status-Options.html
>>
>>100159394
i dont think ill ever really become a programmer because all the project recommendations are so uninteresting.

>make a video game!
i fucking hate video games, i wouldnt finish it.
>make a database thingy!
okay. what the fuck does that mean exactly though. i mean, i could just write "username : password" into a .txt file and call that a database. this is so dull and nondescript.
>make a photo viewer!
that is literally just writing a window wrapper for an image library. i did it in ten minutes already. fuck off.


like seriously what is there to do to practice to get good with to get a job
>>
>>100167348
get a different job, we definitely don't need more people who hate programming in the IT industry.
>>
>>100167348
>to get a job
Here's you, employed.

>Boss: Make a thing!
>You: I don't like that.
>Boss: You're fired.
>>
>>100162791
on windows unless you're using wsl2 something slows down something slows posix shells down to an extreme degree, my guess it's something like kernel resource contention
windows doesn't seem to like the fork-exec process spawning model or ghetto attempts at aping it MSYS2 and/or cygwin do
>>
File: IMG_0880.jpg (638 KB, 2873x1151)
638 KB
638 KB JPG
I got my books :)
I don’t really need K&R anymore but I could use a re-read just in case.
The rest are sure welcome and will enjoy them in the coming nights.

Feeling good bros, what are you reading?
>>
>>100167643
>Me: Guess I have nothing to lose anymore. *kills former boss*
>Police: You're arrested!
>Me: Alright.
>five minutes later my thermonuclear device goes off
>Me: What exactly confused you when I said I had nothing to lose anymore?
>>
>>100167348
>practice
you think it's supposed to be fun?
>>
>>100167348
write a kernel, you'd learn a lot
>>
designing a language and wondering why other languages mix the syntax for functions and procedure calls. shouldnt you be able to tell what returns something and what performs side effects without looking it up?
>>
>>100168064
This "problem" has never occurred to me and I can't wait to see the solution you have in mind
>>
>>100168064
How's your syntax for that going to work? I think you could just use a naming convention to show whether it has side effects or not
>>
>>100168064
At their hearts, they're just GOTO statements that you trust to come back having done some changes to your system memory.

"Function," "procedure," "method," etc. are social constructs that say more about potential optimization and how much thought must be put into using them without making mistakes than they actually describe different things.
>>
>>100166707
>What is media_id in say, Media Studio and the others? anime_id or manga_id?
good point. i didnt think about that. not sure how to handle this. i dont think i want want to split studio into AnimeStudio and MangaStudio, what if an anime studio also works on manga or vice versa? but also multiple studios can work on the same media so i cant just make studioID a field on anime/manga either. any ideas on how to handle this?
>>
>>100168064
are you using procedures for side effects exclusively? Can functions not have side effects? Can your procedures return a value?

I am writing a language and the call syntax for both will likely be identical, but declarations for pure functions require the pure keyword. I also distinguish routines from functions as routines are inserted at the callsite, do not context switch, and have all of their locals allocated in the calling scope. Routines have a magic, non-shadowing scope and can return a value, subroutines are just a block of code and use the
assumed
keyword to borrow from the calling scope:

subroutine assign_fizzbuzz_string(assumed int i, assumed string output)
{
if( i % 3 == 0 ) output += "fizz";
if( i % 5 == 0 ) output += "buzz";

if( output.size() == 0 ) output = to_string(i);
}


endpoint function main() -> int
{
for(int i = 0; i <= 100; ++i)
{
string output;
assign_fizzbuzz_string(i, output);
System::stdout::printf("{$output}\n");
}

return 0;
}


currently, subroutines are slated to be implemented by [spoiler]string substitution[/spoiler].
>>
>>100167348
>i dont think ill ever really become a programmer because all the project recommendations are so uninteresting.
make something for someone else then
>>
When people say
>make a video game !!
do they mean program an engine from scratch, use raylib or sdl, or like use an existing engine like godot or unity?
>>
>>100168768
Counterquestion: how are you supposed to make an engine if you've never made a game? Now, if you can look at the source code of such an engine and immediately find things that you can do better, then sure, do everything from scratch. But if you can't, then don't.
>>
>>100168807
>how are you supposed to make an engine if you've never made a game?
yea i would not have gone straight for engine dev if that were the case
>>
>>100168528
You want a table for a Studio, with studio_id and all the studio information.
You can make a table Anime_Studio that holds anime_id and studio_id as PK together.
With this, a studio can have multiple animes, and an anime can have multiple studios that worked on them.
That's how many-to-many relationships are implemented.
Analog for Manga_Studio, many mangas, many studios.
And since you have studio_id for Studio, you don't need to split Studio into MangaStudio or AnimeStudio.
To consider, how reality changes how you can model data: if an anime can only have one studio asigned to them and not multiple, and there is always an studio associated, then you can put studio_id as FK on the Anime table.
>>
>>100168819
Are you the guy who's converting his C++ engine to Beef? Who doesn't want anything to do with memory management? Because if that's the case you absolutely should've acquired more experience before going into engine development.
>>
>>100168865
No i'm just looking to get better at programming so I can start rolling in that cheddar cheese and have my parents stop hating me
>>
>>100168901
In that case:
>>100166178
>>
>>100168913
>https://www.rfleury.com/p/untangling-lifetimes-the-arena-allocator
t-thanks
>>
>>100168850
how about adding separate ranges to the id fields? for example making all anime start with from 1000 and manga from 2000?
>>
>>100168969
You can do that. You will have to remember the constraint and enforce it.
How will it look like?
1000, 1001, 1002, ..., 1999,
10001, 10002?
11000, 11001?
Maybe by having only 100 animes and not having a huge archive?
>>
>>100168407
you forget that in anything but asm you reset all register state to what it was before the call prior to returning.
>>
>writing functions to handle my filesystem
>"why not make it one function that branches with a jumo table?"
>i am somehow using like 12 registers
>nothing makes fucking sense, i have a REPZ movsb (lol) with rdi and rax (???)
what the fuck happened here? Good luck me of tomorrow.
>>
>>100169254
>in anything but asm you reset all register state
No you don't, you clown. You only do that for registers that the ABI declares non-volatile, the volatile ones have to be restored by the caller (if the caller needs their values, which isn't a requirement).

>>100169287
>REPZ movsb
Don't unless you have to deal with more than 512 bytes: https://stackoverflow.com/questions/33480999/how-can-the-rep-stosb-instruction-execute-faster-than-the-equivalent-loop
>>
What can I make using Pascal? What kind of project can I do with pascal by myself? Anyone here learning pascal? Any advice?
>>
>>100168807
Because making an "engine" whose only user is you is infinitely easier than making a game that people will actually play?
>>
I’m going to learn programming but before learning a language, is it a better idea to learn the command line first? That seems more IT related no?
>>
>>100169541
yes you will have to unless your time is worthless
>>
>>100169541
I don't know if you're on Windows or Linux but if you're on Linux you'll want a surface level understanding of bash.
On Windows I assume you'll want to know PowerShell and probably Command Prompt too.

If you're doing bash and you're using arrays or the "set" command you ar ein, "use a real language instead" territory.
I don't know where that line is drawn in the Windows tools.
>>
>>100169580
I'm a windows user and I want to learn more, is learning Linux commands better than Windows powershell commands? What is more useful? I am thinking if I need to learn more I have to switch to Linux but which one I'm not sure.
>>
>>100169613
Install Gentoo.
>>
>>100169629
Why are you telling me to install Gentoo? It looks extremely difficult to manage and I have not stepped outside of shindows lol. I need something beginner friendly
>>
>>100169660
it isn't difficult at all, my grandma could do it
>>
>>100169613
>What is more useful?
The Windows tools, because you're on Windows.
>>
>>100169742
that wasn't the case since WSL, he unironically would also have better time learning how to work with GCC/LLVM than MSVC too.
When I still used windows, I unironically used mingw, it comes with pacman and by then I already realized that GNU won my heart.
>>
>>100169742
But there's not much to do is it? can you give me an example what can i do with it because windows differs from linux and it's like all the stuff is already there and you do not need to even open the terminal at all lol
>>
>>100169813
yes windows is for playing video games only
>>
>>100169613
just use powershell (not the one that ships with windows by default)
it's cross platform (i use it on my phone) and has all the unix commands as shorthand for equivalent powershell commands
batch is actually fucking trash, it's not worth learning on any circumstances
>>
>>100169853
>phonenigger giving advice
lmao, bash is the only relevant shell used by everyone who has a job in IT sector
>>
>>100169880
android phones are just sandboxed linux environments once you install termux, the only reason i bring it up is powershell works the same largely everywhere
i use it to run lightweight servers

and all text based shells suck
i'm not doing any (de)serialization just to handle basic shell usage because a bunch of idiots think the unix philosophy entails pointless and worthless boilerplate

bash is relevant because it's the default, it's not good
>>
>>100169987
android is not GNU hencefore bad
>>
>>100169358
>muh ABI
lol tell that to gcc
>>
>>100168015
>goodluck having even basics such as wifi and gpu support
literally only learning that half of your firmware is proprietary and free systems are impossible
>>
why didn't they ever add a lengthof operator to C for arrays
or at least standardize a lengthof macro in a std header that has compiler magic etc to produce an error if not applied to an array
>>
>>100170369
because in cnile's mind, anything that can be done with "little more work" is not worth implementing standardly, that's why shit like strstr doesn't have alternative implementations that accept size of string so it doesn't have to strlen every single time.

#define lengthof(x) (sizeof(x) / sizeof(x[0]))


Isn't really that bad and you can write it from memory. There's one off problem for strings but noone uses C for strings, strings and text and words and concepts and abstractions are for people who have internal monologue.
>>
>>100170441
>strings and text and words and concepts and abstractions are for people who have internal monologue.
bait
>>
>>100170484
People who have internal monologue don't run strlen more than once per string per program and that's impossible to do with string.h in C because they don't.
>>
>>100170043
There's nothing to tell.
>>
>printf("%d\n", sizeof "abcde");
6
>>
>>100170504
Yes, isn't C just a beautiful language?

#include <stdio.h>
#include <string.h>

#define NIGGERS (4096 / (sizeof("NIGGER") - 1))

char NIGGER[4096];

int main() {
memset(NIGGER, '\0', sizeof(NIGGER));

for (size_t i = 0; i < NIGGERS; i++)
memcpy(NIGGER + i * (sizeof("NIGGER") - 1), "NIGGER", sizeof("NIGGER") - 1);

while (NIGGER) {
fputs(NIGGER, stdout);
}
}
>>
>>100170495
it's ok in that sense but that has nothing to do with string.h though
>>
>>100170495
Nah, people who have internal monologue learn from Linux:

#define array_size_constant(array) ((sizeof(array) / sizeof((array)[0])) + \
sizeof(typeof(int[1 - 2 * !! __builtin_types_compatible_p(typeof(array),typeof(&array[0]))])) * 0)
#define strlen_static(string) (array_size_constant(string) - 1)
>>
>>100170524
*memcpy. memcmp, memset, etc..
>>
>>100170524
it has everything to do with standard library, \0 is brain damage that was obsoleted in 2 weeks after its conception, and stupid cniles didn't even have foresight to just hide length somewhere behind a pointer the way they do with malloc.
>>
>>100170536
Thanks for this inane soup of retarded symbols, but I will just stick to
>std::array<T,N>::size
because my time isn't worthless.
>>
>>100170544
>my time isn't worthless
You lack internal monologue, and you're posting here. Your time is obviously completely worthless.
>>
>>100170558
if I lacked internal monologue I'd be coping with stopgap solution that breaks the moment the array is accessed anywhere outside its definition scope
>>
>>100170569
?
>>
>>100161956
>Does it return multiple parameters?
No, it doesn't. Nothing ever does. Why would it? What is this gay shit?
Higher order fuckery and partial application are easy to misuse, yes, but it's an issue to be solved through purely social means. I imagine a combination of ml-specific arity+fixity-aware highlighting in IDEs, and a standartized API between linters and electroshocking equipment.
>>
>>100166177
No one employed uses haskell or ocaml, so step 1 is to quit your job
>>
>>100170596
>nothing ever does
Meanwhile in rust retards are allowed to return 100+ variables like this

fn swap(x: i32, y: i32) -> (i32, i32) {
return (y, x);
}

fn main() {
// return a tuple of return values
let result = swap(123, 321);
println!("{} {}", result.0, result.1);

// destructure the tuple into two variables names
let (a, b) = swap(result.0, result.1);
println!("{} {}", a, b);
}
[/cde]
>>
>>100170117
yeah well you do what you can, plus just learning about the processor/memory, filesystems and the scheduler puts you ahead of 99% of programmers in 2024.
>>
>>100167348
How about rootkits? Or scientific computing? I dare you to reproduce the results of reed & hill, 1973.
>>
>>100170673
no it doesn't, it is completely irrelevant and useless knowledge, if my system's scheduler was ever a problem I'd probably be putting my code on a system that doesn't have one, not tinkering with it.
>>
File: Ohne Titel.png (368 KB, 2188x1371)
368 KB
368 KB PNG
I'm working on a parser for Live2D models in Typescript. The goal is to display and animate VTubter models and such w/o using proprietary code.
>>
>>100170848
And that's why you'll always remain a brainlet.
>>
>>100170858
What the hell is a Tubter, Hanz?
>>
>>100170858
>tests for a personal project
cba
>>
>>100170862
post your superior scheduler tranny
>>
>>100161576
Good choice anon. Caml rulez.
>>
>>100170903
However, you seem to got that humor thing down. You could always work as clown.
>>
>>100161576
learn Haskell
only downside is no module functors
>>
>>100159636
you sound like a bitch lol
>>
>>100170923
so you haven't written superior scheduler than what's available in industry and larp as superior?
>>
>>100170968
... guess I was too hasty. Your jokes aren't laughable.
>>
>>100170984
yeah I guess you can only amount to tinkertrannying and larping about how great templeOS is or something and haven't actually done anything of value
>>
>>100171005
Never mind, you suck at this.
>>
>this tranny is consistently posting same cope here everyday larping about how much of a heckermen he is
>>
>>100171047
You seem to have a problem with others being superior.
>>
>>100171168
Ok so how long will we all wait for your superior task scheduler to be posted ITT?
You have one last chance, my (You)'s are running out.
>>
File: full_dc_sphere.webm (3.94 MB, 1280x720)
3.94 MB
3.94 MB WEBM
>>100159394
I've been working on my game engine in Vulkan and C. Most recent visual progress is this dual contoured voxel sphere.

Currently doing some infrastructure work after going full on into dual contouring. Next up is a voxel editor, then terrain.
>>
>>100171185
Like I care?
>>
OCaml or Golang for web dev?
>>
>>100171208
Golang is used by Google, OCaml isn't used by anyone, take a guess.
>>
>>100170927
why Haskell over OCaml?
>>
File: Ohne Titel 2.png (80 KB, 799x761)
80 KB
80 KB PNG
>>100170858
Great success!
>>
>>100171185
>my (You)'s are running out
this isnt reddit
>>
>>100171266
post the cute animegirl
>>
@100171283 (You)
that's why begging for replies doesn't work
>>
>>100171208
If you're not using OCaml you should be using ASM, C, C++, Rust, Fortran or Haskell. Otherwise you're doing something wrong.
>>
>>100166117
>the entire point of GC is NEVER having to worry about memory at all.
Let us know when the GC starts to fuck up and you have to manage the GC by hand.
>>
>>100171317
>mixing in worthless dead languages with C++
>>
I cba to write tests
>>
>>100171357
Tests are literally worthless for anything but libraries, library is the only type of project that has no usecase on its own, as it is a component of another project that does. If you wrote a program, and god forbid actually use it, you don't need tests because all bugs will be found by using it.
>>
>>100171389
Tests, specially TDD, are good to ensure you don't break anything as your application scales/refactors, but you need to write a truckload to actually be useful.
>>
>>100171535
Or maybe just don't break things that aren't broken?
>>
>>100171551
I'm going to assume you're a non-dev or entry level.
>>
>>100171582
>have tests
proprietard software is buggiest there is
>have code reviews
proprietard code is most unreadable there is
>have paid programmers, team leaders, management work on optimizing programming
proprietary projects are most unmaintainable there is
>you're not even entry level
being unemployable in software industry is a medal of honor
>>
>>100161956
git gud
>>
File: paredit_assert.webm (107 KB, 648x364)
107 KB
107 KB WEBM
>>100171357
make it easy for yourself to write tests by refactoring your program and configuring your editor with good macros and hotkeys. Then you'll automatically write more tests.

>>100171389
I don't like using buggy software and I don't like programming with buggy functions, so I try to iron out as many bugs as possible in each part of the program as I write it.
>>
>>100168170
Its not exactly a problem i was just wondering if itd be nicer to use.
>>100168171
Its smalltalk inspired so instead of
reciever.function(p)
im messing around with
(reciever function:p)
for pure functions and
[reciever proc:p]
for procedures/impure functions. Its interesting but im not sure if its stupid or helpful desu.
>>100168576
Functions are pure, procedures are impure. Both can return multiple values. You can return nothing with nil and void means it never returns (im not sure if that means functions cant return that then. im doing this for fun idk fuck all about this stuff desu). You can define procs and fns anywhere and they only have access to the scope theyre defined in unless you pass in a pointer but since everything is strongly typed you have to be explicit about that anyway so i dont think its a big deal.
>>
>>100171911
>lisp
don't worry noone will find any bug even if you blatantly put it in
>>
>>100171927
>Its interesting but im not sure if its stupid or helpful desu.
it's very helpful until you realize that now you do same amount of thinking except you have to remember which syntax is which and to write correct syntax every time when all you needed to do before is mark variable that you don't want to be modified as constant
>>
>>100170927
There's a half baked backpack in GHC.
>>
>>100171927
look into Pascal, it makes a clear distinction between procedures and functions.
>>
>>100159641
collapse() would need to be a coroutine, get out faggot
>>
File: 1704364893718778.jpg (72 KB, 400x400)
72 KB
72 KB JPG
I am trying to generate the 10 millionth fibonnacci nunber in base (1+sqrt(5))/2 and it has taken over 5 days now.

Is there anything I can do to speed it up? I was banned from the compute cluster.
>>
>>100173268
>Is there anything I can do to speed it up?
can't tell you much without seeing your code. But generally, memoization is going to speed up a recursive algorithm for something like fibonacci.
>>
>>100173268
how does a O(1) operation take 5 days?
>>
>>100159641
penis.Remove<Foreskin>()
>>
>>100173268
>I was banned from the compute cluster
Why? You told them what you were doing?
>>
>>100165342
how the fuck do you not know golang?
I legitimately hate golang and rarely use it, but I just treat it like it's a really shitty C that brianlets think C should be.

just say something about muh CSP and context or something and you'll wo some dipshit that doesn't realize how bad the language actually is.
Ironically when I write go I almost never use channels or any of the shitty features.
>>
>>100165342
I forgot to mention. talk a lot about how you love wrapping your errors with fmt.Errorf or some shit as well. Go toddlers are obsessed with their utterly shitty error handling and are easily amused.
>>
https://pkg.go.dev/errors
ya, make sure to study this for lulz.
>>
>>100173996
just like cniles with their utterly shit error handling, just like ziggers with their utterly shit error handling, just like rustroons with their utterly shit error handling
>>
window registry dumper anon have you been diagnosed with schizo yet?
>>
>>100174158
he single handedly killed the activity of this thread
dtg used to be one of the most active generals

honestly its impressive when you look past how sad it is
>>
>>100174195
It's ok anon, I will spam it with something more unintelligible while I'm not banned because for some reason I keep getting banned unlike that faggot.
>>
>>100174195
These threads have been dead for a while though. I remember back in the mid to late '10s we'd get several threads per day.
>>
>>100174195
I bet you haven't been posting here for more than a month or two
>>
>>100174441
are you implying that hexdumping schizo is a newfag?
>>
How do I build Dear ImGui as a DLL?
>>
>>100166082
Areas have very specialized usecase. If you are making same few allocations every frame then sure use areas, but everything with longer lifetime still needs classical dynamic memory management.
In a well designed engine you shouldn't have much or any allocations that happen every frame, rendering areas useless.
>>
>>100159394
I'm working on an image scraper as part of personal project module on a coding platform. It's been great as a hobby for someone not in tech field.
>>
>>100159394
Retard question but this is the first time I've ever done this, so please bear with my retardation. I'm building a cnn from scratch as a learning tool and for w/e reason jupyter notebook cannot reference conv.py. Is this because I saved it as a .ipynb?
>>
>>100175129
https://github.com/giladreich/cmake-imgui
>>
>>100175266
oy vey just reserve 6 million gb of ram, what do you need 12 million gb for, it's not like I'm actually allocating 18 gb goy, REMEMBER THE 24 MILLION (until I commit)
>>
>>100176134
it must feel great to larp as a midwit when you're a dimwit who doesn't understand that arenas don't allocate memory more than once
>>
>>100171226
monads
>>
>>100176247
Um no bro reserving 6 gorillion virtual auschwitz is not allocating
>>
>>100175877
>building a communist news network
not gonna help you with that one, Trotsky
>>
>Want to write modern TypeScript for modern Node.js
>In all of my .ts files, I have to import my own shit my specifying my own .ts files with a .js ending
>If I don't want that I also need to add tsc-alias into my compiling process
There is no way this is real life, this is so weird. The out-of-the-box correct way of importing in ESM targeted TypeScript is to import your own TypeScript files with a ".js" ending? cmon
>>
>>100176844
>TypeScript soidev learns that it's just JavaScript with syntax sugar
>>
>>100176888
What does that have to do with anything. Do asm compiled languages have to leak asm shit into their design because they are just syntax sugar for asm at the end of the day or what
>>
>>100176931
>Do asm compiled languages have to leak asm shit into their design
yes
>>
Should a hash table data structure use the 32-bit or 64-bit version of its hash function?
>>
>>100176959
The only relevance is do your hash tables get bigger than 4 billion elements
>>
>>100176959
Kind of depends how are you going to use it?
If you can make sure there are no collisions, 32bit might be bit faster.
For a generic implementation I would use 64bit
>>
>>100176844
You can pass ts-node loader to node to make it able to load .ts files or you can use webpack or similar to handle module resolution and transpilling. With the right set up you can make it update your code in real time without having to retard the program(HMR). That's how I do it.
>>
>>100176931
http://unixwiz.net/techtips/win32-callconv.html
>>
>>100177021
64 bit isn't really useful unless you have more than one level of hashing or too much RAM
>>
make a new one
>>
>>100177030
>ts-node
Sounds interesting, also complex enough that it would be yet another thing that you'd want to understand incase shit goes wrong. So meh
>webpack or similar to handle module resolution and transpilling
Yeah, that's basically what tsc-alias does, on a small scale. It handles relative imports by adding the .js into the dist-files. I don't quite understand why the regular typescript compiler claims that it cannot understand/do this. It knows that the target is ESM + Node16+, it knows that Node16 requires .js endings, it must understand my import statements and what I am important ... why can it not figure out that it needs to add .js. Surely if whatever tsc-alias or webpack does can figure it out, tsc itself can as well?
>>
>>100172676
Fortran has a call keyword.
>>
>>100177176
Welcome to webdev. JS is le bad is just a meme, in practice you won't even see it under the layers and layers of tools, abstractions, languages and shit. There is so much if it that everyone can have their own OC tool set and configuration to make it all work. I worked in this for like 8 years and never heard about tsc-alias kek. sorry I can't help you, no one really understands how it all works, just small snippets of it. Best I can tell you is that AFAIK ESM is literally Hitler about file extensions for some reason in some cases. I only recently moved to ESM from commonjs.
>>
>>100177012
>>100177021
>Kind of depends how are you going to use it?
it's for a normal usage
>>100177021
>If you can make sure there are no collisions
that's precisely why I'm asking, to know if there won't be collisions due to the fact that the hashed value is smaller
>>100177067
>more than one level of hashing
you mean that 64-bit would be useful if you computed the hash of a hash? that is good to know
>>
>>100177372
No, I mean if you actually used hash bits in a way that benefits having more of them. For example https://abseil.io/about/design/swisstables
>>
>>100177306
All of this just so the co-workers can stop crying about muh verbose java and can use some destructure, on-the-fly-type creation syntax BS. Idk, it is kinda cool in many cases, but I really don't think it makes such a big difference at the end of the day.
>>
>>100170573
He's talking about array decay and how that macro would break when a pointer is used.
>>
>>100174158
Why would I?

>>100174195
Good.

>>100174229
This guy is much more in need of a schizophrenia diagnosis. He thinks occasionally posting about something on topic is spamming - in better days people like him would've been brought to the funny farm for "electrotherapy".

>>100175266
>Areas
>he doesn't understand that lifetime unification isn't lifetime shortening
You have never used *arenas* in a proper context. It's trivial to implement, say, thread frame structures within them, where each instance of a recursion knows where it started off so that it can reset all the memory it allocated for itself.
>inb4 just use the thread stack for that
Thread stacks are limited in size. Arenas can be massive.

>>100177692
*That's the point of that macro*! If you use a pointer with it it generates an array with a negative size, which is illegal and causes the compiler to complain about it - which is much better than calculating an invalid value at runtime.
>>
File: file.png (38 KB, 800x720)
38 KB
38 KB PNG
Would tokio's tasks outperform OS threads at downloading lots of small files (200KiB) from net?
>>
schizo came back, thread is over, make a new one when he's gone
>>
>>100177830
>You have never used *arenas* in a proper context.
I used areas in my ray tracer.

>It's trivial to implement, say, thread frame structures within them, where each instance of a recursion knows where it started off so that it can reset all the memory it allocated for itself.
Areas need to be reset at some point to free the memory. If you are making a game engine, things like entities or textures or whatever are going to live for long time, possibly for majority of the program lifetime. Allocating them on an memory area means you can't reset it at all, causing memory leaks.
The only usecase where memory areas are useful is when you are expected to create many objects with similar lifetime that can be freed at the same time. If your game engine is making this kind of allocations, then your engine is shit. You need to redesign it, not add another allocator as a bandaid solution.
>>
>>100177937
>I have to allocate and deallocate game objects
low IQ retard, have you considered that you can allocate an array of objects for maximum amount of objects you will ever need and then simply never deallocate them? Just don't draw unused ones, don't update unused ones, don't do anything with unused ones, any logic you have to implement to handle swapping them around in array will still be more performant than allocation and deallocation constantly.
>>
>>100177983
>have you considered that you can allocate an array of objects for maximum amount of objects you will ever need and then simply never deallocate them?
That's not only super inefficient on memory, but also again, an allocation that will exists for the entire duration of the program and will cause your precious memory areas to swell and swell until they run out of memory.
>>
>>100178018
any fragmented brainrotten solution you will come up with will allocate more virtual memory than what I wrote, many successful games do it and it's efficient
>>
>>100177927
>implying that would help

>>100177937
>I used areas in my ray tracer.
You can't even spell the word correctly, mate.

>Allocating them on an memory area means you can't reset it at all, causing memory leaks.
... what the actual fuck are you talking about? Do you *understand* arenas even in the slightest?

There is absolutely nothing that prevents you from placing static data into a second arena that never gets reset. There is also absolutely nothing that prevents you from not resetting the entire arenas, but only up to a certain point. I have just *explained* how you do that, by having the function remember where the essential data ends and then use anything beyond that as a scratch area.

So, I repeat what I said: you have *never* used ***arenas*** in a *proper context*. Never ever. Do it again, and properly this time, or just shut the fuck up.
>>
>>100178018
>That's not only super inefficient on memory
Again, *what the fuck are you talking about*? Do you *understand how virtual address space and commitment works*?
>>
>>100178087
this retardation reminded me of https://github.com/nodejs/node/issues/39499 kek
>>
>>100178122
>instead is limited by 2**64 bytes (which is very large)
The number is wrong, the physical bus is 48 bits wide, and the MSB usually indicates if it's a kernel address or not, limiting it further to 47 bits or 128 TiB, but other than that he's correct. Furthermore, if you're convinced that you won't need all of your committed memory for the future you can tell the kernel just that (MEM_DECOMMIT on Windows, and all the insane flags of madvise on Linux).
>>
>>100178180
Linux already has 5 level paging, the end of the rope is near, sister.
>>
>>100178062
What successful games do is flexible object pools. Not static allocations and memory areas.

>>100178076
>... what the actual fuck are you talking about? Do you *understand* arenas even in the slightest?
Yes

>There is absolutely nothing that prevents you from placing static data into a second arena that never gets reset.
If you are retarded, then yes, nothing prevents you from doing that. But if you are actually using your brain when programming, you will realize there is no need to use memory areas for memory you are not planning to free.

>I have just *explained* how you do that, by having the function remember where the essential data ends and then use anything beyond that as a scratch area.
What you are describing here sounds like red zone, which is completely different concept from memory areas.

>So, I repeat what I said: you have *never* used ***arenas*** in a *proper context*. Never ever.
Lmao

>>100178087
>Again, *what the fuck are you talking about*? Do you *understand how virtual address space and commitment works*?
Of course. But you seem to not really comprehend it at all.
>>
>>100178259
virtual memory is already flexible you fucking retard, if you allocate 1TiB arena and only ever make 56 objects, only as many pages as it takes to fit 56 objects will ever be used by the process
>>
>>100178274
Games usually do not happen to have only 56 objects that never go away and produce new objects, all with different lifetimes and references.
>>
>>100178292
yes instead games have set limit of objects they can render and that limit never changes, midwit
>>
>>100178259
>you will realize there is no need to use memory areas for memory you are not planning to free
I've sat an entire minute in front of that statement and have absolutely no idea what it is you're trying to say here. Why *wouldn't* you want to hold on to memory you *know* you'll still need? That's what this entire state fuckery of userspace allocators like malloc is about: managing memory chunks to avoid having to trap into the kernel, because that's slow.

>What you are describing here sounds like red zone
That's because you're a mouthbreathing imbecile who doesn't know what a red zone is or even why it's important. The point of a red zone isn't to preserve anything before the stack pointer, but to avoid having to adjust the stack pointer in the first place by promising to not touch anything after the stack pointer as well (up to a certain point). Now, you *can* do that with arenas as well - why would you adjust the end marker if you know that no subsequent code will have to make allocations in the arena? That's one add and one subtract that don't have to be included in your code - but that's not the point I was talking about, because arenas don't need to know anything about thread suspensions and signals and anything that would require the kernel to place the current CPU state onto the stack. Arenas have no red zones because there's (in the optimal case, which you should strive for) no one contending to write into the same memory you're writing into, not even the kernel.
>>
>>100178381
>userspace allocators like malloc
yeah it's funny how cnile brain damage lead to malloc being just a glorified arena allocator of arenas, it already clusters similar size allocations together for example
>>
>>100178407
malloc ist unser Ungluck.
>>
>>100178381
It's very challenging to find a job right now for new grads, period, the language unfortunately isn't usually the limiting factor.

That said Golang is great and I've seen and heard from plenty of recruiters even still in 2023 hiring for positions. Mostly senior ones unfortunately, but it at least shows me that there are doors open for Go folks.
>>
File: 1704976910009419.jpg (2.07 MB, 3024x4032)
2.07 MB
2.07 MB JPG
>>100173363
>>100173403
its doing some properiatary things so i cant post the code, but i also need to calculate (1+sqrt(5))/2 to the power of 10 million

>>100173711
i ran the code without batch scheduling it to avoid the queue because it seemed like if you request over 100GB of RAM they put you at the back of the list and i figure i needed around 500GB of RAM i also requested it for 10 days because i thought it would take a while. apparently each cpu core only gets around 2gb RAM so my program can only use 1 core to run but required 250 cpu cores to be allotted also i was warned not to do this but i thought it could finish fast enough that they wouldnt notice

i got a refund though
>>
>>100178806
I love how the cats share the same brainless stare as their poster.
>>
>>100178806
https://youtu.be/Ckqf1NjPPgw?t=37
>>
>>100178806
you sound like you have actual brain damage

>>100178903
>anthropomorphic bird named Mordechai
Normies let their children watch this garbage and see nothing wrong with it
>>
>>100179044
>see nothing wrong with it
Good.
>>
>>100179044
https://en.wiktionary.org/wiki/Mordecai
>Etymology
>Borrowed from Hebrew מָרְדֳּכַי (mordocháy).

https://en.wiktionary.org/wiki/מרדכי#Hebrew
>Etymology
>Unknown; many hypotheses have been advanced, a prominent one of which is that it ultimately derives from Akkadian 𒀭𒀫𒌓 (Marduk), compare Elamite 𒈥𒁺𒋡 (MAR-du-ka4).

https://en.wiktionary.org/wiki/Marduk#Akkadian
>Etymology
>Ultimately from Sumerian 𒀭𒀫𒌓 (damar-utu /Marduk/).
https://en.wiktionary.org/wiki/𒀭𒀫𒌓#Sumerian
>Etymology
>From 𒀭 (determinative for "god") + 𒀫 (amar, “calf”) + 𒌓 (utuk, “of the sun”), literally "calf of the sun" or "solar calf".

What's the issue?
>>
>>100179123
>calf of the sun
>for a bird
next people will be calling potatoes "apples of the ground"



[Advertise on 4chan]

Delete Post: [File Only] Style:
[Disable Mobile View / Use Desktop Site]

[Enable Mobile View / Use Mobile Site]

All trademarks and copyrights on this page are owned by their respective parties. Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.