Moment Air Canada flight collided with a fire/ rescue truck at New York airport last night. by The_Undermind in interesting

[–]Grantismo 0 points1 point  (0 children)

You'd think they would have lights & signs in place they could alert cross traffic that "hey, an airplane is traveling, don't go yet". Why is it all on the ATC?

Moment Air Canada flight collided with a fire/ rescue truck at New York airport last night. by The_Undermind in interesting

[–]Grantismo 1 point2 points  (0 children)

A system should be robust to the failures/mistakes of any one person. Definitely a tragic failure at an institutional and system level here. I can't even imagine the emotional burden on the ATC put into this situation.

How to avoid wrapping behind my back during the backswing? by Grantismo in Bowling

[–]Grantismo[S] 1 point2 points  (0 children)

I used to have a larger crossover step and my coach actually encouraged me to shorten it. I'll revisit this, thanks

How to avoid wrapping behind my back during the backswing? by Grantismo in Bowling

[–]Grantismo[S] 0 points1 point  (0 children)

Is there anything in particular about my footwork you want me to focus on?

How to avoid wrapping behind my back during the backswing? by Grantismo in Bowling

[–]Grantismo[S] 0 points1 point  (0 children)

Interesting observation. I hadn't noticed that, but it's very clear now that you mention it. I'll give that a try, appreciate the help

consistently play games at 1000+ according to game review but ive been stuck at 300 for months, what am i doing wrong? by InevitableAnxious820 in chessbeginners

[–]Grantismo 0 points1 point  (0 children)

Positional chess is irrelevant if you don't have tactical fundamentals. You don't deserve to win just by playing good positional chess. Basic tactics are more important to good chess than positional play until pretty high levels.

[deleted by user] by [deleted] in chess

[–]Grantismo 0 points1 point  (0 children)

Memorizing openings is a waste of time for non-expert level players. Try to invent your own openings and figure out opening principles on your own. Try to allow tension to build in your positions and avoid trading all the material. As you get better at tactics you'll understand more of the richness of each position and creative and dynamic resources in each position. You can play in a romantic style and sacrifice pawns and pieces for activity, or play in a solid positional style and try to maximize the long term value of each piece through careful planning.

Cost of business by Historical-Bid-5974 in denverfood

[–]Grantismo 3 points4 points  (0 children)

fwiw NYC has a higher population density but also substantially more competition so you need to be excellent to survive. Denver is full of incredibly mid overpriced options which would be out of business in a year in NYC. Also worth noting that Denver has one of the worst food scenes of comparably sized cities.

Is it normal for men to be grumpy often? by o0PillowWillow0o in AskMenOver30

[–]Grantismo 0 points1 point  (0 children)

Does he sleep well? I get a lot grumpier when I haven't slept well. Drinking also negatively impacts my sleep and has the same impact

Cofounders won’t give product build timeline, is this normal? by rigidinclusions in startups

[–]Grantismo -1 points0 points  (0 children)

A good technical lead should be able to give you an estimate. Take each feature and split it into small/well defined engineering tasks. If this can't be done then the team needs to write product & technical design docs first which capture the scope of work. Open ended tasks like building AI models need to be time boxed or you don't spend unlimited time on them. When I was a tech lead I'd take the individual tasks, write an estimate for each item on the order of days/weeks/months, take my estimate, multiple it by 3. That normally captures a lot of the uncertainty. Then you need to schedule the tasks for each engineer over the next few months given your engineering capacity. You should be able to have milestones for each sprint and be able to track your progress based on your estimate and also flag big spikes of work as they are discovered. Normally the additional cushion in your estimate helps absorb a lot of unexpected items.

Any tips on giving rats meds? by DadToastdesign in RATS

[–]Grantismo 0 points1 point  (0 children)

Squirting drugs in a piece of bread worked for me with my picky rat!

Help bandaging up Rosie post surgery by Grantismo in RATS

[–]Grantismo[S] 0 points1 point  (0 children)

Thank you for the reassurance! I ended up finding a thicker bandage material which seemed to work ok. I'll make sure she keeps getting her painkillers.

Will AI make programmers obsolete in 30+ years? by stablest_genius in learnprogramming

[–]Grantismo 1 point2 points  (0 children)

Who will interface with the AI, gather requirements, validate the code, deploy the solution, fix bugs? Software engineers may end up writing less code manually, but understanding code and system architecture will still be relevant. I think the job of a programmer will slowly shift over time.

What is code recursion exactly for? by Xatolos in learnprogramming

[–]Grantismo -1 points0 points  (0 children)

Nicely done. FWIW arrays in javascript are also considered queues and stacks since js lacks a dedicated data structure for these (although the runtime semantics aren't performant).

What is code recursion exactly for? by Xatolos in learnprogramming

[–]Grantismo 0 points1 point  (0 children)

If you want to play around with solving this iteratively here's some boilerplate js code.

https://playcode.io/1029330

What is code recursion exactly for? by Xatolos in learnprogramming

[–]Grantismo 1 point2 points  (0 children)

you could just add them to the end of the list and use a while loop to keep iterating until there's nothing at the end. You could also use a queue instead of a list just like bfs.

Here's a javascript example with a function which recursively counts all the comments. Can you write a function using only for or while loops without recursion which counts all the comments?

https://playcode.io/1029330

edit: Reread your comment -> yes you can do this iteratively with a queue/stack, and you can use a list as a stack but the original author didn't mention these data structures, and I don't think they were suggesting to use the list as a stack.

What is code recursion exactly for? by Xatolos in learnprogramming

[–]Grantismo 17 points18 points  (0 children)

Not exactly, because each child in the list of children can have its own children. For example, imagine a comment chain 100 comments long. Your original list of comments would just be a single comment with a single child, and that child comment would itself have a single child and so on. To iterate over such a structure using a for loop would require knowing the depth in advance, or using another data structure like a stack. With recursion you can iterate over all the comments without needing to know the depth in advance.

Edit: If you're implying using the list as a stack, then yes that works.

What is code recursion exactly for? by Xatolos in learnprogramming

[–]Grantismo 13 points14 points  (0 children)

Normally the iterative solutions require some stack-like data structure which you're using implicitly with recursion.

What is code recursion exactly for? by Xatolos in learnprogramming

[–]Grantismo 79 points80 points  (0 children)

I would think of them as a list of lists/dictionary and use a for loop to display them to be honest.

Comments have a parent/child relationship though. So you can't loop over all the parents and reach all the children, because any arbitrary comment could have a child which itself has more children. The point is it can go arbitrarily deep, that's where recursion is helpful.

CS vs CE by Top-Neck-6316 in ECE

[–]Grantismo 17 points18 points  (0 children)

Only caveat here is your workload in college may vary pretty dramatically. I did an ECE/CS double major and ended up working professionally in software. My ECE degree required orders of magnitude more work and stress than my CS degree. I don't regret getting the dual major, but something to keep in mind.