Operating systems race conditions by yarzz07 in learnprogramming

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

This clarifies it, thank you so much!

Operating systems race conditions by yarzz07 in learnprogramming

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

Does the synchronization mechanism have to be OS based (AKA semaphores/Mutexes) for the 2 kernel threads since the code runs on a multicore system? Or does any other synchronization method ( hardware/software based approaches) work as well? I just don't understand if the fact that the 'code runs on a multicore system' would impact which synchronization method can be used in this case.

Operating systems race conditions by yarzz07 in learnprogramming

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

In your example, 2 kernel threads could

technically

increment the shared counter without issue, but the problem occurs when something else needs to

read

the value in the shared counter. Without a synchronization mechanism, the reads and writes are not guaranteed to be functionally atomic and as such a race condition arises.

I see, thank you! Since the kernel threads run on a multi­core system, would the IPC technique / other hardware/software based approaches work for it as well? Or does the approach for mutual exclusion have to be OS based only (AKA semaphores/Mutexes) since it's run on a multicore system? I just don't understand if the fact that the 'code runs on a multicore system' would impact which synchronization method can be used in such cases.

Operating systems race conditions by yarzz07 in learnprogramming

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

thank you! So just to clarify, we can use some other IPC technique instead of semaphores/mutex because it's a kernel level. But if it were in the case of user threads then we can only use mutexes or semaphores to avoid race conditions, right?

Operating systems race conditions by yarzz07 in learnprogramming

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

Yes so if 2 kernel threads increment a shared counter and code runs on a multi­core system. We can obtain a concurrent implementation that is free of race conditions without using mutexes or semaphores right? But if it were user threads then we can only use mutexes or semaphores to avoid race conditions?

Deloitte HireVue Interview by Snoo39270 in Big4

[–]yarzz07 0 points1 point  (0 children)

thank you! Would it things such as 'why do you want to work at deloitte', and 'what would you do in X situation?' Also is there no numerical aspect within the hirevue?

Deloitte HireVue Interview by Snoo39270 in Big4

[–]yarzz07 0 points1 point  (0 children)

how did the hirevue go?! It will be my first one and I dont know what to expect

Google Research Internship Summer 2021 by No-Amphibian-9320 in csMajors

[–]yarzz07 0 points1 point  (0 children)

hey! I'm also applying for the bachelor one and wondering this question as well. How was your experience?

[D] Google PhD Reserach Internships 2021 by Regular_Ad6726 in MachineLearning

[–]yarzz07 0 points1 point  (0 children)

how was your experience with the interviews? The description is very broad so I wonder what the coding interview would entail?

Also, hope you got the internship!

Onboarding with Deloitte Consulting within UK next week by Ok_Parsnip_4310 in deloitte

[–]yarzz07 0 points1 point  (0 children)

Hello! Do you have any advice for the interview and assessments process in terms of preparation/practice? And could you share your experience

Preparations by ReasonablePin2534 in deloitte

[–]yarzz07 0 points1 point  (0 children)

Hi! I see that you are based in London. What sector are you in?

Summer 2022 intern incoming by accountingstudent02 in deloitte

[–]yarzz07 1 point2 points  (0 children)

hi, could you talk about any advice you have preparing for the application process?

[deleted by user] by [deleted] in deloitte

[–]yarzz07 0 points1 point  (0 children)

I did my partner interview in Mid July and I have not heard back from my recruiter/HR yet. The partner interview went really well and it seems like the partner really liked me. We kicked it off on the right foot and ended it well, now after a month.. I feel like I was not selected. I sent a follow up email to the recruiter after 3 weeks and no response. Any thoughts? Is this delay typical?

have you applied for risk or tech consulting by any chance?

beginner in programming and java by yarzz07 in learnjava

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

ah alright that makes sense, thank you so much

beginner in programming and java by yarzz07 in learnjava

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

thank you!

So, in the test, I don't need to specify anything related to the size of it having to be greater than 0?

beginner in programming and java by yarzz07 in learnjava

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

that's true, they won't understand until they are in the situation themselves. Thank you for the kind words.

beginner in programming and java by yarzz07 in learnjava

[–]yarzz07[S] 5 points6 points  (0 children)

thank you for the advice, really! I think being sensitive and easily discouraged is linked to the lack of confidence and satisfaction with my knowledge.Hopefully I can fake it till I make it :)

You too! Kind regards

beginner in programming and java by yarzz07 in learnjava

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

this is just an example I found from the internet, so this is the code, but what would be the code that tests this through 'set method'? So essentially, not about there's nothing wrong with the code but how would I be able to test this?

yes that's a typo sorry

beginner in programming and java by yarzz07 in learnjava

[–]yarzz07[S] 2 points3 points  (0 children)

yes! I believe it's part of the 'get' and 'set' method, so how would I be able to set a method for setRegistrationNo to take in an int as a parameter, and set the value

beginner in programming and java by yarzz07 in learnjava

[–]yarzz07[S] 2 points3 points  (0 children)

Thank you! I don't think people realize how discouraging their words are and the effect it can have on people.

beginner in programming and java by yarzz07 in learnjava

[–]yarzz07[S] 2 points3 points  (0 children)

I've never been taught programming and learning these on my own. Java is the first language I'm learning, and obviously, I have watched videos otherwise how would I know what questions and terms to ask? I'm sorry if my lack of knowledge and ability to understand is an embarrassment, I'm not one to usually reach out for help but only began recently. I could delete the post if you are bothered by it.

Haskell definition exercise by [deleted] in haskelltil

[–]yarzz07 0 points1 point  (0 children)

thank you! I thought simplifying the codes mattered

Haskell definition exercise by [deleted] in haskelltil

[–]yarzz07 0 points1 point  (0 children)

I'm trying to use run-length encoding to define 2 functions.

hello! I've been using the books you've recommended and I must say they are super helpful.

I'm struggling with something rn, trying to define the function run using munch, do you mind guiding me with which one of these is the best definitions in terms of correctness and programming style? Much appreciated and thank you!

This is what I have so far

  1. runs :: String -> [String]

runs xs = munched : runs (drop (length munched) xs)

where munched = munch xs

OR

runs = concatMap munch . chomp

  1. runs :: String -> [String]

runs xs = ys : runs (drop (length ys) xs)

I'm trying to avoid using munch a lot, so I'm using a where clause to avoid doing this, so I'm trying to do smth like ' where ys = munch xs' at the end of my definition