IT/Software career thread: Invert binary trees for dollars.

Needless

Toe Sucker
9,169
3,268
Cant you just use the Android studio emulator and step through for debugging?

Maybe? almost all crashes are on the OnePlus 5T device though and i don't know how to replicate it in the emulator to figure it out lol

Android Studio also doesnt seem to have OnePlus/Samsung emulated devices, it's weird.
I think Samsung might have their own platform though which i haven't looked into
 
Last edited:

sadris

Karen
<Donor>
21,131
80,758
I have something that should occur about 7 times per day . What equation should I use to have it trigger, on average, 7 times per day? I wanted to do something like MTTH (mean time to happen) like in EU4/CK2, also known as MTTF in adult life, but I can't seem to find a simple equation to do so

Maybe I'm using scipy/numpy wrong but the equations on page 5 here don't seem to be correct.
 

TJT

Mr. Poopybutthole
<Gold Donor>
40,932
102,735
Can we just do this in some coding language please, why do you need a specific calculation for it?
 

alavaz

Trakanon Raider
2,001
713
I have something that should occur about 7 times per day . What equation should I use to have it trigger, on average, 7 times per day? I wanted to do something like MTTH (mean time to happen) like in EU4/CK2, also known as MTTF in adult life, but I can't seem to find a simple equation to do so

Maybe I'm using scipy/numpy wrong but the equations on page 5 here don't seem to be correct.

I honestly have no idea what you are asking but it seems like if you set a chron job to run it every 3.4 hours. It will happen about 7 times per day.
 
  • 2Like
Reactions: 1 users

TJT

Mr. Poopybutthole
<Gold Donor>
40,932
102,735
Or be ultra ghetto and just put that shit in the windows task scheduler.
 
  • 1Barf
  • 1Like
  • 1Worf
Reactions: 2 users

sadris

Karen
<Donor>
21,131
80,758
I honestly have no idea what you are asking but it seems like if you set a chron job to run it every 3.4 hours. It will happen about 7 times per day.
That's what I'm going to do. I was thinking it was way too complicated.

While true:
sleep(3hrs)
sleep( random(10min, 70min) )
do_something()
 

TJT

Mr. Poopybutthole
<Gold Donor>
40,932
102,735
That's what I'm going to do. I was thinking it was way too complicated.

While true:
sleep(3hrs)
sleep( random(10min, 70min) )
do_something()

Okay but is this just the trigger for another application or batch job or some shit like that? A little more context maybe? Mildly certain there's some best practices around not putting an program into intermittent sleep for sleep(12240).
 

Noodleface

A Mod Real Quick
37,961
14,508
Sleeping for 3 hours in a program is absurd. You'll want a scheduler to kick off your program. Every 3ish hours or whatever you decide
 

alavaz

Trakanon Raider
2,001
713
If you really want to get fancy, you'd probably want to write some sort of daemon to execute whatever based on an event.
 

Mist

Eeyore Enthusiast
<Gold Donor>
30,396
22,176
We're going to spend thousands of dollars to rebuild, replace, ship and redeploy a customer's entire environment because 3 senior engineers didn't notice / was full on a xen server, and no one wants to admit that I stopped it from crashing 3-5 times a day by deleting 10gb of logs that didn't rotate properly because of a hung process, even though it is not crashing anymore (or filling up the partition) after I fixed it.

I'm just going to start telling customers that their servers are haunted and we have to dispatch an exorcist.

EDIT: The customer told them to go fuck themselves on the downtime for the redeploy, since it is fixed.
 
Last edited:
  • 2Worf
Reactions: 1 users

Noodleface

A Mod Real Quick
37,961
14,508
Really enjoying the job so far. They had me hit the ground running. Dell is massive, massive, massive and dell emc is the Enterprise storage portion. We're writing BIOS for a fuck ton of products now. Just feels good to be excited (in a work way) to be at work. I will say though, bios is a huge thing to learn for such a small code footprint, and there's a ton of history that I don't know about. I know some of it and I know a lot about CPU architecture and pcie topology but it's just such a huge undertaking.

It's one of those things that when asked to implement something there's a LOT of reading to get through and understand. Sometimes it's just flipping a single bit in an Intel register and having the entire system configuration change. Not to mention that's if Intel coded it properly. Everyday is a challenge, I don't think there will.be many easy days.

Also my boss wants weekly 1:1s and daily status updates. Seems excessive and too overhead-y at that rate.
 
  • 2Like
  • 1Solidarity
Reactions: 2 users

Siliconemelons

Avatar of War Slayer
10,789
15,127
Well not to un noodle Noodleface Noodleface new job (gratz!) - but finally got through the stupid long process to get a free POC in of Datrium to replace our storage layer on our VMWare Horizon / esxi / vcenter based VDI stuff (my current Higher Ed job, not the new IR Dir Job... transitioning between the two for the next 2 months)

Excited to get Datrium in and a "real" storage solution vs Open-E JovianDSS that we have now...that is a good product and cheap...but NOT what we signed up for nor what we expected.

Edit: the annoying process is 100% on OUR end with purchasing mangers, VPs and general counsels going round and round and round... Datrium was like "sign this basic POC form and we are good"
 
  • 1Like
Reactions: 1 user

Ao-

¯\_(ツ)_/¯
<WoW Guild Officer>
7,879
507
Edit: the annoying process is 100% on OUR end with purchasing mangers, VPs and general counsels going round and round and round... Datrium was like "sign this basic POC form and we are good"
Oh god, I know this pain all too well. We basically got a 1 year free POC from a company because I couldn't get our contracts lawyers to agree to pay them.
 

Noodleface

A Mod Real Quick
37,961
14,508
Ran into a stupid problem today. Before you say anything, I realize the easy solution is rename the define.

We have source A
C:
#define CR 0x0D

Then source B
C:
struct {
...
UINT64 CR :1;
...
} somestruct;

Compiler fails because it's a mixed c/c++ codebase and says the struct is trying to redefine a constant. What do?

Easy solution is to rename the define, but CR is the standard way of indicating a carriage return. Any other options ??
 

Deathwing

<Bronze Donator>
16,386
7,388
You could namespace your struct. Though, I'm assuming they're both C code.

#ifdef guards for the struct?
 

Noodleface

A Mod Real Quick
37,961
14,508
I think the define is in a cpp and the struct is in c, but the struct is Intel code that I can't change. I need them both so don't think ifdefs will help, unless there's something I'm not seeing.

The easiest solution is going to bother my core because CR is the nomenclature for carriage return and changing it is dumb.
 

Deathwing

<Bronze Donator>
16,386
7,388
Is it the compiler specifically that's failing, or the linker?

If the usage of Intel's CR is rather limited, you might be able to get away with #undef it. That doesn't feel great though.
 

Neranja

<Bronze Donator>
2,605
4,143
Ran into a stupid problem today. Before you say anything, I realize the easy solution is rename the define.
C:
#include <first.h>
#undef CR
#include <second.h>
#define CR 0x0d
But boy will this explode in your face when you try to access CR in that struct. By then it is hopefully someone elses problem.
 

The_Black_Log Foler

Stock Pals Senior Vice President
<Gold Donor>
43,734
40,637
Any you bros use kotlin and/or have strong opinions on kotlin/native being a competitor for react native in Mobile cross platform development?
 

Neranja

<Bronze Donator>
2,605
4,143
Any you bros use kotlin and/or have strong opinions on kotlin/native being a competitor for react native in Mobile cross platform development?
In a view from very high above Kotlin is nice insofar that you can mix Java and Kotlin, which makes it a good fit for existing projects. And the language is slimmed down and has some advanced features like coroutines.

But as someone from a C/C++ background it still targets the JVM, which still has the smell of turd polishing, but its the same feeling with every language where "you don't have to care about pointers and freeing your resources, the garbage collector will take care of it for you".

React on the other hand is JavaScript, with the claim "don't waste your time recompiling". JavaScript:

206838


In our goal to explore the solar system we should seriously make efforts to colonize Mars. JavaScript programmers are all so important to society in general and computer science in particular that they should have the privilege to be on the very first ship sent to Mars. All of them. Which we will call "Ark Fleet Ship B"
 
  • 2Like
  • 1Worf
Reactions: 2 users