Problem of the day
Tip 1 : Prepare for basic implementation of data structures
Tip 2 : Be good at OOPS Concepts
Tip 1 : Be honest with your resume.
Tip 2 : Mention 1-2 projects in resume such that a healthy discussion can take place.
This is one of the questions-
To avoid the race condition, the number of processes that may be simultaneously inside their critical section is?
The answer to the problem is 1. Race condition bring in the idea of critical section. Critical section is a mutually exclusive section whereby more than 1 process reading or writing the shared data is prohibited. Critical section is the part of program code where the program changes global variables, writing files etc. So entering more than one process in their critical section may cause ...
There are 25 horses among which you need to find out the fastest 3 horses. You can conduct race among at most 5 to find out their relative speed. At no point you can find out the actual speed of the horse in a race. Find out how many races are required to get the top 3 horses.
Make group of 5 horses and run 5 races. Suppose five groups are a,b,c,d,e and next alphabet is its individual rank in tis group(of 5 horses).for eg. d3 means horse in group d and has rank 3rd in his group. [ 5 RACES DONE ]
a1 b1 c1 d1 e1
a2 b2 c2 d2 e2
a3 b3 c3 d3 e3
a4 b4 c4 d4 e4
a5 b5 c5 d5 e5
Now make a race of (a1,b1,c1,d1,e1).[RACE 6 DONE] suppose result is a1>b1&g...