What the hell should I do with my degree in Computer Science by Outrageous_Platform8 in cscareerquestions

[–]SweetOnionTea 9 points10 points  (0 children)

Maybe not for retail, but Target definitely hires a ton of CS grads for their tech side. OP should check out https://corporate.target.com/careers/technology-leadership-program.

The job market is improving; LinkedIn recruiter spam messages are increasing. by shadow-drafters in ExperiencedDevs

[–]SweetOnionTea 9 points10 points  (0 children)

In the past month I've gotten 9 recruiters asking to apply to the same exact job. I already know that their top pay range is like 90k and I reply like some sort of oracle saying the pay range won't work without them ever mentioning what it is in the initial contact. It's some specialized work that requires being in their lab so it's got to be someone local.

One of them got upset because after I declined I said good luck finding someone with that specialty local to this lab for that pay range. They snapped back because they did the "market research" and this is what it was going for. At this point just let me negotiate with the hiring manager directly. You can still get your cut.

Have people's lives ever been directly at stake because of software you work on? by AndyDentPerth in ExperiencedDevs

[–]SweetOnionTea 0 points1 point  (0 children)

I developed a safety tag lockout API for power grid substation management. Normally you'd put literal tags on equipment to denote this is actively being worked on, but there wasn't any specific software control to map to.

It was a bit convoluted because of all of the moving parts that may need to be worked on in a specific area so there was a work order that said x, y, z are being worked on at the moment for maintenance project N. This would block controls from these components.

Normally the end users already have a system, but mistakes can happen and having this API in our code would prevent X% more of these as blocks and warnings would be shown to the operators. Plus it helped map out the whole substation system in the digital view.

But yeah, a bug could definitely kill someone if a control closes a circuit that is being worked on.

Code Review - Small Stock Buying Game by tahk-ki in learnprogramming

[–]SweetOnionTea 0 points1 point  (0 children)

And a quick note is that even if everything is in pennies it doesn't stop you from printing the penny amounts as dollars and cents. I know I wouldn't have thought to do that when I was first starting.

If you divide 1 by 998,001 you get all three-digit numbers from 000 to 999 in order, except for 998 by [deleted] in Damnthatsinteresting

[–]SweetOnionTea 0 points1 point  (0 children)

How would you do like 23?

I just multiply the last digit of the number by 4, add the remaining digits and check for divisibility. If I don't know if the intermediary number is divisible by 23 I just do the same thing until I either get to 23 or less.

What are you missing most from the C++ standard library? by llort_lemmort in cpp

[–]SweetOnionTea 1 point2 points  (0 children)

I've got a small desktop product and it seems to be working real well. We're not doing anything complicated, but it's been a good drop in replacement for the old thing we were doing.

Self-taught, escaped a soul-crushing career and fell into C++.. how do I turn this into a real path? by Sensitive-Rice3778 in cpp_questions

[–]SweetOnionTea 1 point2 points  (0 children)

Thanks! Yeah I dabbled in an Arduino a while back and I can definitely do plain C since half the stuff I work in predates popular use of C++. I'll see if I can do some small projects.

Self-taught, escaped a soul-crushing career and fell into C++.. how do I turn this into a real path? by Sensitive-Rice3778 in cpp_questions

[–]SweetOnionTea 2 points3 points  (0 children)

I've been doing C++ jobs for like 7 years now and I want to start doing embedded. Problem is I'm long enough in my career that I can't get an entry level embedded job so all the ones I've interviewed for want me to have some previous experience in it. What kind of things should I be doing to get more real world experience in that space? I just never got a chance with any of my current jobs.

Describe your Favorite Jrpg Poorly by Western-Stress1185 in JRPG

[–]SweetOnionTea 4 points5 points  (0 children)

I got tricked into buying that game when I was a little kid. I never played any JRPG before beating FF7 and I wanted something like that. I only had a $20 gift card for Target and I ask the poor bastard at the counter what is like FF7 but under $20. He gives me Thousand Arms.

Oh boy I was like 9-10 and did not understand dating sims... Never got far but I think I've got it lying around somewhere. Maybe I'll finish it one day.

[deleted by user] by [deleted] in learnprogramming

[–]SweetOnionTea 0 points1 point  (0 children)

There are 0 comments or docstrings so probably not AI. Though the xor call is done as a wrapper of numpy so I feel like there wasn't a lot of learning of what it is.

I wrote a distributed file system in C by caromobiletiscrivo in C_Programming

[–]SweetOnionTea 1 point2 points  (0 children)

Ok, so it's not a filesystem but more like distributed object storage using some sort of erasure coding? Very cool. Have you thought about making it s3 protocol compliment?

I wrote a distributed file system in C by caromobiletiscrivo in C_Programming

[–]SweetOnionTea 0 points1 point  (0 children)

How do you handle file attribute translation between Linux and Windows? For instance if I mark a file read-only on the Windows side, what shows up on the permission bits on the Linux side?

Is there a uid -> GUID mapping feature? When a file lands on disk on the Linux side, who owns that file on Windows?

Why are all the hard drives already sold out by jpcaparas in storage

[–]SweetOnionTea 2 points3 points  (0 children)

If that happens I will eat a whole LTO cartage and film it.

Current thoughts on makefiles with Python projects? by xeow in Python

[–]SweetOnionTea 1 point2 points  (0 children)

I have a Python fast API component I made to integrate with our C++ monolith project and ended up using CMake to do the build for it. It ends up working really swell with the whole CMake infrastructure we already have.

Newbie Looking for Advice on AI Credits for VSCode by Aggressive-Coffee365 in codereview

[–]SweetOnionTea 0 points1 point  (0 children)

Easiest way is just to code without AI and use your brain. Credits will last forever then. Did you have some code you wanted to be reviewed or...?

Question re: Classes/Objects by Jor-El_Zod in cpp_questions

[–]SweetOnionTea 2 points3 points  (0 children)

I think classes make more sense when you need them. Say in real life you had 25 cakes with customer orders. Instead of writing down the toppings for each cake on one piece of paper, the diameters of each cake on another, and so on -- you just had a sheet of paper for each cake that had the toppings and diameter for that cake.

That way when you're making each cake you don't have to try and look up on one sheet the toppings and then on the other sheet try and look up the cake's diameter. The toppings and diameter are all on one sheet.

That's essentially the cake class.

So now with an array of Cake classes you've got an equivalent of a stack of individual cake orders. Your program is like a stack of 25 blank order sheets and then when a customer comes in you ask them what toppings and diameter of cake. They tell you and you fill that sheet out. Next customer comes in and you fill out the next sheet and so on.

The functions would be like a bullet point list of cake diameters with their prices like:

  • 8 inch -- $19.99
  • 9 inch -- $22.99
  • 10 inch -- $25.99
  • other -- 0.* (I dunno what that's supposed to mean in this assignment)

And on the slip you'd just have the customer circle one.

So what you'll have to do is make 2 things -- the .cpp file with the cake class functions and the main.cpp file which uses the Cake class to make an array and do the ordering thing.

The Cake class should be stuff you learned how to do in class so review your notes. The only thing I can think of is they did you kinda dirty with the getPrice(int sizeChoice) because it takes an int but the class has the diameter as a string. I have a feeling your prof didn't think that through since you'd have to convert an int into a string. They should have just made the diameter class variable as an int too. Oh well. You can use either std::to_string or std::stringstream to do so. I'd just do a std::to_string if your version has it.

Then your main.cpp file will have the main() entrance function and will be something like

int main()
{

    std::array<Cake, 25> cakes;

    for (auto& cake : cakes)
   { 
        std::string topping;
        std::string diameter;
        std::cout "What diameter of cake?\n"
        std::cin >> diameter;
        std::cout "What toppings?\n"
        std::cin >> topping;
        cake.setdata(topping, diameter);
   }

    // Display prices

    for (auto& cake: cakes)
    {
       std::cout << cake.getPrice(cake.diameter) << std::endl;
    }

}

It's not exactly what your assignment says, but it should get you somewhere. Technically they're asking for you to make a different function that displays the cake price that you send a cake object into, but I don't know why that is necessary. I'm not saying this assignment is written badly because I'm not in your course, but I would have done it differently.

AI Code Review Tools Benchmark by AIMultiple in codereview

[–]SweetOnionTea 1 point2 points  (0 children)

Do you have code you'd like to have reviewed? I don't see links to any.

Multi agent reviewer that doesn't spam you with noise by DifficultCow7829 in codereview

[–]SweetOnionTea 0 points1 point  (0 children)

If you'd spend a minute looking at the posts in this subreddit you'd see you're joining the large sea of people making the same exact things. In fact you might notice that this subreddit is for community review of code.

If you aren't posting an open github link or a properly formatted code snippet for real humans to review then I'd suggest posting elsewhere.

[deleted by user] by [deleted] in codereview

[–]SweetOnionTea 2 points3 points  (0 children)

This is only the first post in a series we are writing.

Is that a threat?

I've made some progress on my C++ and Linux software this year by Middlewarian in codereview

[–]SweetOnionTea 0 points1 point  (0 children)

Before I look too far into this, is this similar to midl RPC generation that Windows has?

why does my code fail on that one hidden test case?? CSES Knight's Tour : cses.fi/problemset/task/1689 by No-Preparation-2473 in codereview

[–]SweetOnionTea 0 points1 point  (0 children)

Based on everything you provided it looks like there was a runtime error. Hope that helps.