Shortest Job First Scheduling (Solved Problem 1)

Поділитися
Вставка
  • Опубліковано 7 січ 2025

КОМЕНТАРІ • 68

  • @neel_artstrong
    @neel_artstrong 3 роки тому +190

    The algorithm shown here is Shortest Remaining Time First (SRTF) not Shortest Job First (SRF). In description it's written that both are same which is not true. SJF is a non-preemptive algorithm while SRTF is preemptive at arrival. I am referring Operating Systems Internals and Design principle by William Stalling. There may be a mistake due to very similar names.

    • @PriyankaSingh-pn8xv
      @PriyankaSingh-pn8xv 3 роки тому +7

      Yes... Right... It is SRTF not SRF

    • @rometvinnal7035
      @rometvinnal7035 3 роки тому +7

      This should be the pinned comment.

    • @shuyangnie2446
      @shuyangnie2446 2 роки тому +7

      well, shortest job first with preemption is the same as shortest remaining time first

    • @adityaprasad1574
      @adityaprasad1574 Рік тому +3

      Yes bro you are right....He taught us wrong.....I had also verified it from books,professors,batchmates..........
      Padhane nahi ata ....thik se padhaya kro.....thoda sa ke liye confusion bhar jata hai😠

    • @anmolnegi-vt2kb
      @anmolnegi-vt2kb Рік тому +1

      Also he said in previous lecture that preemptive SJF is sometimes called SRTF

  • @chrismalingshu
    @chrismalingshu 3 роки тому +28

    Sir, I understand what you taught very clear. I applied it to solve my test questions and my lecturer said it was wrong. With tons of evidences & references, he still insisted that my solution is WRONG. Almost everyone in the class solved it by referring to ur video.
    How a frustrating learning process :( Anyway, I believed you are the right one.

    • @ramak885
      @ramak885 2 роки тому

      keep learning

    • @sabahsamwatin
      @sabahsamwatin 2 роки тому +4

      I think the one he showed in this video is for preemptive scheduling which are SRTF and Round Robin. The non-preemptive scheduling are SJF and FCFS. SJF and FCFS are solved in the same way. His FCFS video is correct. This video should be fixed.

    • @kbbadhri9889
      @kbbadhri9889 10 місяців тому

      Same bro 11:58 😊

  • @yusen-t_t9872
    @yusen-t_t9872 5 років тому +31

    Just wish my professor could teach like this...

    • @greythirdeye1714
      @greythirdeye1714 4 роки тому +2

      I like his voice... Soft and fluent english 🧡

    • @aryanali574
      @aryanali574 4 роки тому

      @@greythirdeye1714 hour 6ho 0yi0h

  • @giannawilliams7037
    @giannawilliams7037 3 роки тому +7

    you guys are the reason im gonna graduate college

    • @kbbadhri9889
      @kbbadhri9889 10 місяців тому

      Did you graduate college?

  • @pranavbadhe6489
    @pranavbadhe6489 Рік тому +3

    Just wish my professor could teach like this.........

  • @ayushiydvKG
    @ayushiydvKG 7 місяців тому +2

    SJF and SRTF are different. SJF holds for preemptive mode while SRTF holds for non-preemptive process (arrival time)

    • @wassimaroudj1635
      @wassimaroudj1635 Місяць тому +2

      the opposite dude, SJF is for Non-preemtive while SRTF is for preemtive .

    • @ardakeser573
      @ardakeser573 Місяць тому

      Thanks for the heads up but it's the opposite.

  • @mdkamrankhan4032
    @mdkamrankhan4032 5 років тому +2

    Very good explanation. Thank you Sir.

  • @sairajdas6692
    @sairajdas6692 5 років тому +3

    Excellent explanation!

  • @lolz8930
    @lolz8930 4 роки тому +2

    This was extremely clear and helpful. Many thanks.

  • @lofiking6033
    @lofiking6033 5 місяців тому +2

    This is not SJF algorithm. This is Shortest Remaining Time First algorithm. In case you are wondering what is the correct SJF, when a proccess starts, you dont compare any proccess that comes next, but instead let it finish no matter what. Correct your video's title or the description, because it misleads students.

  • @shade5848
    @shade5848 5 років тому +6

    hey! I have a question. how do I calculate waiting time if (for example) P1 was 3 times processed?

    • @jinkangshuai4468
      @jinkangshuai4468 5 років тому

      in my opinion ,totalwaiting time- total first and second excited time -arrival time; total waiting time =the waiting time after arrival +second waiting time and third waiting time

  • @proteanguy3411
    @proteanguy3411 3 роки тому +16

    Sir you should write in title it's preemptive shortest job first 😑

  • @nilawmanandhar8412
    @nilawmanandhar8412 Рік тому +3

    Sir the title is bit confusing as it is Shortest Remaining Time First (SRTF) or preemptive SJF not just Shortest Job First (SJF) as the initial thing that comes in mind after hearing SJF is non-preemptive because what you are doing here is preemptive scheduling but generally SJF is non-preemptive in arrival

    • @Jatish.M
      @Jatish.M 9 місяців тому

      i am also having the same doubt

    • @naughtyjiyansh533
      @naughtyjiyansh533 8 місяців тому

      Preemptive SJF is called the SJRTF

  • @CSKAASIPRASANTHA
    @CSKAASIPRASANTHA 2 роки тому

    SJRT is the pre-emptive form of SJF

  • @elmargentertainment5683
    @elmargentertainment5683 Рік тому +1

    you are great!

  • @mohan67662
    @mohan67662 5 років тому +2

    Sir please explain OOPS concept...

  • @sitanshubhugun8219
    @sitanshubhugun8219 2 роки тому +2

    what if the arrival time is the same?

  • @PKMKB93000
    @PKMKB93000 Рік тому +1

    Sir here if we calculate TAT for P1 it is coming out to be 27 using (CT-AT) formula but when we are calculating WT using (TAT - BT) formula then WT is coming different as compared to (TWT- Execution previous in millisecond - AT) formula. Theoretically TAT should be 27 only

  • @arashpardeepsingh1551
    @arashpardeepsingh1551 4 роки тому +1

    Sir how these actually happens in cpu how it knows or estimate the burst time of the process

  • @unlockwithjsr
    @unlockwithjsr 3 роки тому +4

    Hello sir, I think P4 intrerrupts P3 since 5 is less than 6

    • @amritarao8514
      @amritarao8514 3 роки тому +5

      P4 COMES AT 8 SECONDS, THAT TIME P3 ALREDY EXECUTED 2 SECONDS SO REMAINING TIME IS 4 SECONDS , SINCE 4

    • @monicamukherjee3758
      @monicamukherjee3758 2 роки тому

      Shortest Remaining Time First Algorithm is used in this case as in the question it is asked to do so. SRTF and SJF are not same. If one uses SJF then P4 will interrupt P3 but since SRTF is used P3 will continue.

  • @HayaAB
    @HayaAB Рік тому

    Grateful👍👍

  • @Unknowns330
    @Unknowns330 2 місяці тому

    I think your information is incorrect for the fact that sjf is non preemptive meaning the process is not stopping until completion sk p1 get execution untill finish and then apply short job first

  • @JadenSmanga
    @JadenSmanga Місяць тому

    Isn’t in the previous video you said P2 didn’t wait for the CPU( P2 waiting time=0), but now there’s a contradiction coz you saying P2’s waiting time=2?

  • @PaAGadirajuSanjayVarma
    @PaAGadirajuSanjayVarma 4 роки тому

    Thank you so much sir

  • @DolaLado
    @DolaLado 4 роки тому

    Thank you.

  • @WESLEYMANOMANO
    @WESLEYMANOMANO 9 місяців тому +1

    thank u sir man

  • @tajudeenlisa8730
    @tajudeenlisa8730 3 роки тому +2

    Excuse me sir since p4 has a smaller burst time than p3 why didn't it come first...

    • @PlRATE
      @PlRATE 3 роки тому

      5:56

    • @juliuspinto5031
      @juliuspinto5031 3 роки тому

      There should have been idle time in between p2 and p4. P3 will never be put into process until p4 has finished processing.

    • @thomasshelby1093
      @thomasshelby1093 Рік тому

      ​@@juliuspinto5031so which one will come first p3 or 04

  • @greythirdeye1714
    @greythirdeye1714 4 роки тому

    Sir how can i deal the theory part of OS??

  • @OurProblemsOurSolutions
    @OurProblemsOurSolutions 8 місяців тому

    Nice video

  • @kunjupulla
    @kunjupulla Рік тому

    You did not cover response time

  • @dhanushsivajaya1356
    @dhanushsivajaya1356 4 роки тому

    Thankyou sir

  • @nysschan
    @nysschan Рік тому

    6:03

  • @mr.gegenpress7750
    @mr.gegenpress7750 10 місяців тому +1

    this is not SJF 😅

  • @asfandi69
    @asfandi69 Рік тому

    Sir hurraira ny to aesy nai krwaya

  • @riyajacey9462
    @riyajacey9462 4 роки тому

    Helpful

  • @SohaAhmed-ek4nt
    @SohaAhmed-ek4nt Рік тому

    Answer = 5.5

  • @trendtidetv528
    @trendtidetv528 3 роки тому +2

    it is for preemptive and u solve it for non preemptive schedeuling

  • @vrupesh8080
    @vrupesh8080 Рік тому

    NICE

  • @johnpaulduavis8097
    @johnpaulduavis8097 4 роки тому

    Thank you

  • @rittushsarkar5943
    @rittushsarkar5943 2 роки тому

    SIR IT'S YOUR MISTAKE THAT SHORT JOB FIRST SCHEDULING IS A NON-PREEMTIVE MODE AND IN THIS MODE EACH PROCESS IS EXECUTED UNTIL IT FINISHED COMPLETELY.........

  • @seyyedrizmy4732
    @seyyedrizmy4732 2 роки тому +1

    Bruh this is STRF

  • @robertocastillo7320
    @robertocastillo7320 4 роки тому

    di araival taims

  • @appjosi3345
    @appjosi3345 3 роки тому

    Horrible video!!!

  • @narimanvatankhah1269
    @narimanvatankhah1269 6 місяців тому