Woah..... So this is the power of government engineers

Woah..... So this is the power of government engineers

Attached: EUDRCsJXsAEJ7JH.jpg (980x504, 107.95K)

Other urls found in this thread:

argentina.gob.ar/aplicaciones/coronavirus
twitter.com/SFWRedditVideos

...

Kill yourself brainlet

The fuck am I looking at, codefag?

Attached: 53419869-6597-4AB6-879C-EE55D2F518A4.jpg (1100x618, 48.79K)

>diagnostico_bueno
delete system32

Shitty code with redundant calls. What's your point in terms of politics

Lol, Mexican government?

I think this is a bit below /g/

Attached: data analytics.jpg (670x501, 46.3K)

argentina

you see all the times it says
> bodyTemperature >= 38
that would've only had to be done once

I don't think it's bad; there is an argument to avoid nested ifs, especially if this logic came from a government document that states the guidelines for diagnosis in that form.

This is exactly what goes through your doctor (medical technician)'s head because he isn't legally allowed to make any diagnoses outside of your governments' standards for diagnosis.

H1-B contractors, no doubt.

you wouldn't need nested ifs. Look at the actual logic. That massive if-block only needs to do the temperature compare and then check if any of the 8 other variables is true.

where did the originate

Attached: 1580684669575.jpg (720x480, 343.16K)

bodyTemperature >= 38 && (difficultyBreathing || diabetes || cancer || ..)
is all you need. there's really no excuse for the duplicated predicates either, so either this was made by copypasta or a code generator

Do one if with temperature, then one if that's an or of the other conditions. Much cleaner code

kys

But it can be done with
If (body temperature >= 38 && (difficultyBreathing || condition))

Attached: 06d2237b.jpg (600x486, 37.58K)

if you have kidney disease or liver disease or anything else it doesn't matter as long as your temp is under 38degrees, you are diagnostico bueno!

I mean it works, its not nice or efficient but it works.

There are literally dupicate statements in there. If bodytemp and respiratorydisease is literally in two times on after another. Same with the bodytemp and difficultybreathing and respiratorydisease statement

We all know why

Attached: 1564359873941.jpg (268x367, 14.23K)

>this.handleSaveTest()
it's either pajeet or jorge

>'/cuarentena/'

kek

Modern compilers will optimize it the same

wait are lines 415/416 and 423/424 duplicates?

but yeah bodytemperature >= 38 and at least one of the other conditions then first block, if bodytemperature >= 38 then next block, else next block, the 3rd block is redundant

>I don't think it's bad
Pajeet, no.

Boolean algebra, bitch, do you know it?

>wait are lines 415/416 and 423/424 duplicates?
Yeah I noticed that, too. lmfao

Whenever I see shit like that it's usually the end result of the requirements constantly changing and the dev just not caring anymore and wanting the task to be done.

How's that side project coming along?

Attached: 1585379598988.png (2408x1996, 652.56K)

This is exactly the case. Guaranteed.

Leaving the bad coding practices to aside, the real problem in this code is that it only says your not healthy if you have a temp over 38. Everything else doesn't even matter because if you have any of the health issues listed you're still diagnostic-bueno so long as your temp is under 38. It may as well just say if your over 38deg quarantine if your under good diagnosis. It's shit medicine on top of garbage code, being my point

Lol I code in notepad. Fuck your fancy vims and emacs etc. Notepad nigga

it's not hard to just delete your redundancies before you deploy it, unacceptable

Frankly the whole thing should just be if (patient) history.replace ('/Do_Your_Fucking_Job_DOCTOR_DIAGNOSE_YOUR_PATIENT_USING_THAT_BIG_MEDICAL_SCHOOL_BRAIN/');

I'm assuming this is in the context of coronavirus, there is probably a separate test for those other conditions

Now do the actual algebra part so the computer doesn't redo work a dozen times.

Truly based burger

It's frustrating being told to modify some minor thing 50 different times while having a full workload of other crap todo.
Bonus points when they modify it that much that it goes full circle ending up how it originally was before some idiot decided to make changes.

>Python
>SICP
>"Frameworks"
Going to be in for a shock in the recession when you have to fight real programmers for jobs.
>notepad
just

Diagnostic software even this simple typically does better overall than doctors. Doctors have seen too much and know too many random diseases they can't occams razor it and often get it wrong

bt & db ||
bt & db & x || y || z...

It's sleek, tight, and easy to read/understand the logic behind it. I despise autist niggers like you who over complicate things with loops calling on other loops. It all ends up being spaghetti code that only the monkey who wrote it can understand.

Inb4 HURRR DURRR MEMORY ALLOCATION

We're not living in 80's anymore.

>not nesting
>not using a score system instead of combining booleans
>not using a constant instead of a literal value for 38
and, worst of all,
>manipulating history to go places

Attached: 1576385636328.jpg (800x800, 102.09K)

idk user seems pretty diagnostico bueno to me

Attached: why.jpg (500x441, 23.19K)

I think ud get away with h4xor shit like
t & dr & 1=1 || x || y...
not sure though

more like H1N1 contracrors amirite

if (bodyTemperature >= 38 && difficultyBreathing)
so a fatty on a hot day has coronavirus?

That's what we get for importing 3rd world tier pajeets to do this work, while simultaneously encouraging our own young people to study transgender rights activism and urine cross-stream theory.

Attached: 1579881872575.png (745x518, 243.77K)

Came to post this

To be fair trannies are usually good coders

You have to go back to india

NOBODY CARES CODE FAGGOT.

This doesn't belong on Yas Forums

nuh uh

Pack it up burgers, the Spaniard beat us this time.

the coder was a diversity hire. many such cases. sad. very sad.

stop this nonsense

Jews are behind this.

Google.js

>dog shit code
>js
>shitty js

Hi 1994 called Brendan Eich wants his JS back.
WTF were they paid per line?


>variable bodyTemp repeated unnecessarily
>hardcoded 38 instead of a variable
>decided to make a mountain out of something that could be more logical

Attached: javascript.jpg (229x152, 8.51K)

I love nonsense in a slide thread though

no argentinian here ?

sometimes you end up with weird structures like that if you are trying to code to a spec that is written like that and you want to easily verify that they match up
like if the spec is written "go to hospital if: fever and difficulty breathing, fever and difficulty breathing and diabetes, fever and blah blah etc", you might want to write your code in that same pattern
but probably it was written by retarded pajeets

it gets worse the more you look at it though
> else if temp < 38 push bueno
> else push bueno
Kinda like the picasso of shitty code

>body temp >=38 degrees
youd be dead if your body was 38 F...fucking retard

Attached: aOYA1mE_460s.jpg (460x613, 44.53K)

They are all in Yas Forums, post there

Attached: Javascript Will Never Die My Friend.jpg (550x335, 48.66K)

Not everyone uses retard units.

Argie here, yes that code is real is the coronabot our government build to answer dumb people paranoia the first week of lockdown... now nobody cares

argentina.gob.ar/aplicaciones/coronavirus

To be fair, at least it's comprehensible, so maintaining or updating it would be easy.
Not that JS is particularly difficult to maintain, unless you're having to compile it for ES7 Babel's sake and some retarded front end framework which will 100% break on it's next npm modules update.

You can also be perfidiously evil with JS to the point where someone else reading it would would have to 'beautify' before it becomes obvious what it is - usually you'll see this with little rats dropped on MiTM attacks

what's the else for