No.17701
Algebra?
No.17702
Hardware and software engineers historically tended to not be Mathematicians. Even analog logic is never this complicated.
No.17706
>>17700Post the solution, OP.
No.17710
Doubt there is a smaller than O(n) solution to this problem so plugging it into some program and finding the result is as good as you're gonna get.
No.17711
>>17702compsci Chad's rise up!
No.17725
>>17710Do you think we can do n factorials in O(n) time?
No.17897
https://news.ycombinator.com/item?id=33863718Meanwhile the field de skills whether you like it or not
Marx explains why this happens in capital iirc No.17899
>>17897Software engineering is indeed deskilling quickly. It's pretty crazy to see first hand and since its so quick, its also pretty visible. Nothing to be alarmed about though. We'd just get paid less, but there are counter tendencies as well, eg with more and more engineers needed. Also, the reason it is deskilling is due to amazing tools that make it possible. Someone has to build these tools :)
No.17902
>>17725>>17710Seems like an algebra question and a computational question. First I'd analyze the problem to find a pattern or derivation I can use to make the problem easier to calculate.
It is adding factorials from p-1 to p-5, then modding them. Is there a property here that can help?
If we expand it,
(p-1)*(p-2)…*(p-5)*…*1 + (p-2)*(p-3)*…*1 + …. (p-5)*…*1
Looks like we can factor out some terms. All of the addends/terms share (p-5)! So we can factor it out, what do we get?
(p-5)!*((p-1)*…*(p-4)…+1)
They tell us it is a prime number, so we know there are no common factors with any of the terms. I wonder if we can use that somehow. Either way, that simplification, if valid, cuts down on the amount of factorials you need to calculate. We also know that the answer will be between 0 and p.
There's a detail missing here.
Maybe if we plug this in to the other formula something happens but I don't see how to combine mod operands.
Also maybe, if we start doing them for p=5, 6, 7 we start to see a pattern we could use.
No.17903
>>17902continuing, I'm missing something. I think its this.
https://math.stackexchange.com/questions/2565184/proof-of-wilsons-theoremThese "tricks" you just have to memorize and be able spot them, as well as get used to playing around with the function to tease out patterns.
NB this we barely learned in my undergrad and you don't need it for software engineering. It REALLY helps to learn this for interviews which are important.
No.17906
>>17899>>17897hot take, this isn't a problem since 95% of software dev jobs are just gluing libraries together to solve some business problem and are glorified CRUD apps that handle the day to day business of the accounting department or whatever.
The amount of jobs that actually require a detailed expert knowledge of the sorts of things you learn in a CS degree are actually few and far between.
No.17908
>>17897It's not deskilling, most programming jobs are dead simple and can be done by technicians ("code monkeys"). You don't need engineers for your shitty webapp.
No.17934
>>17924I saw a screenshot of the current hot chat AI thing have a "but steel is heavier than feathers" moment so I am not really worried.
No.17935
>>17934just asked it, took a while (like tens of seconds) but did say they weigh the same.
No.17939
>>17938too easy to cheat on
No.17940
>>17937What's the answer then?
No.17944
>>17938How can an AI get basic math that wrong? This also mistake would be make a mess in programming as computers care about if a value is positive or negative and with unsigned variables it will under flow into near the max value of the bit width of the variable for example with standard byte wide unsigned variable -2 will become FD in hex or positive 253 in decimal.
No.17945
>>17944It's a language model, it was made to produce convincingly looking text, it has no concept of meaning.
No.17954
>>17946Yes, it's basically a party trick.
No.17957
>>17700you're the reason the field sucks
No.18117
Using Wilson's theorem and some algebraic manipulations, we see that ultimately S(p) = -9*24^(-1) mod p. The slightly challenging thing then is computing the inverse of 24 mod p, but computers can do this efficiently, as well as then enumerate through all the prime numbers in a given reasonable range. Using some simple Python code, it turns out that the answer is:
139602943319822
No.18124
>>17702Bit goes in, Bit goes out!
No.18125
>>17946Eliza is pretty good. I'm convinced it's a good tool and should be re-visited. Although capitalism is a fucking horrid system so maybe it will become some dark eliza from hell.
>>18117nice. Maybe I'll look it up later. I was curious about the answer.
No.18127
>>18126It's really nice.
https://www.masswerk.at/elizabot/Try talking about something personal, but take it seriously. I've had some interesting results personally.
I'm convinced that this could be a crude substitute for psychological help in places where it is hard to get it. But the idea of companies making money out of this and pretending its just as good as normal therapy in their predictably deceptive ads makes me want to not even look into it.
No.18149
>You shouldnt be in tech if you did not go to an elitist school that throught you greek math notation
Kill yourself, this is "if you dont know latin you shouldnt be in politics" tier.
No.18150
>>17944>How can an AI get basic math that wrong?BECAUSE ITS A FUCKING DICTIONARY ON CRACK TRAINED ON UNSUPERVISED DATA
No.18152
>>18149Do you mean the summa? It's standard mathematics notation, it has nothing to do with the Greeks.
No.18155
>>18152>Its standard math notation>Using greek symbols>Something they dont teach to you if you didnt go to the highest most elitist school level or university with mandatory math courses.Guess I cannot work in tech if I didnt get top 2% of scores at the end of primary school which determined my whole future, i guess.
No.18156
>>18155The summa is standard high school maths, everyone is taught it. That's not the part of the exercise that necessitates university education.
No.18165
>>18156I wasn't taught that in high-school.
No.18166
>>18155> he's never seen greek symbolsmore like took a single physics course in your entire life
No.18180
>>18166High school physics doesnt use that, niffo.
Nobody here gets through that math notation at all, unless youre in the most elite of elite schools.
No.18184
>>18165>>18180In which country did you attend high school?
No.18185
>>18166Maths notation is optimized for writing on chalkboards.
Today people use computers for maths, maybe it's time to change the notation to some kind of syntax for a math-centric script language.
No.18188
>>18185>Maths notation is optimized for writing on chalkboards.How so? I was under the impression that most of the symbols come from written works.
No.18189
>>18184nta but peak performance evropean high school goer here, never even heard of that symbol
did you take long or short math yourself
Unique IPs: 28