3.8 Infix to Prefix using Stack | Data Structures Tutorials

แชร์
ฝัง
  • เผยแพร่เมื่อ 3 ต.ค. 2024
  • Jennys Lectures DSA with Java Course Enrollment link: www.jennyslect...
    In this lecture, I have described an efficient algorithm for infix to prefix conversion using stack in data structure. Also discussed infix to prefix conversion without stack with example and analyzed both the approaches.
    DSA Full Course: https: • Data Structures and Al...
    ******************************************
    See Complete Playlists:
    C Programming Course: • Programming in C
    C++ Programming: • C++ Complete Course
    Python Full Course: • Python - Basic to Advance
    Printing Pattern in C: • Printing Pattern Progr...
    DAA Course: • Design and Analysis of...
    Placement Series: • Placements Series
    Dynamic Programming: • Dynamic Programming
    Operating Systems: // • Operating Systems
    DBMS: • DBMS (Database Managem...
    *********************************************
    Connect & Contact Me:
    Facebook: / jennys-lectures-csit-n...
    Quora: www.quora.com/...
    Instagram: / jayantikhatrilamba
    #stack #infixtopostfix #jennyslectures

ความคิดเห็น • 552

  • @alixaprodev
    @alixaprodev 5 ปีที่แล้ว +160

    *I am always feeling bored while watching tutorials online but your style of delivering lecture is somehow different. Thanks Ma'am and keep continue. I think that i am not the one who fall in love with your lectures.*

    • @edith3693
      @edith3693 4 ปีที่แล้ว +4

      i feel the same! her 20 min lecture can be finished in 10 mins too!

    • @nazansari9902
      @nazansari9902 ปีที่แล้ว +1

      Yeah, you're right. But tell me how do you make your comment text bold?

    • @Arsh-kd4cq
      @Arsh-kd4cq ปีที่แล้ว +1

      @@nazansari9902 * (your text) * remove space b/w asterisks

    • @nazansari9902
      @nazansari9902 ปีที่แล้ว +1

      @@Arsh-kd4cq *thank you*

    • @nazansari9902
      @nazansari9902 ปีที่แล้ว

      @@Arsh-kd4cq *I got it*

  • @thethinkinlad
    @thethinkinlad 7 หลายเดือนก่อน +17

    BRUH this video actually saved me for my coding assignment (use a stack to convert an infix string to prefix). ALL the coding websites claim that all you have to do is reverse the string, then do the usual infix to postfix conversion, then reverse the resulting string. What they DON'T tell you is that you do NOT pop operators of the SAME priority. All it took was a quick skim through your video to figure out what had gone wrong. Thanks Jenny!

  • @rahulmaurya6451
    @rahulmaurya6451 2 ปีที่แล้ว +65

    India strongly needs teachers like u mam. Harry bhai , Khan sir , Jenny mam, and soo on. We are blessed that u all are born in India ❤️❤️

  • @Mr-kc3pk
    @Mr-kc3pk 4 ปีที่แล้ว +120

    Mam, Really No doubt you are a good teacher.

    • @akashap6330
      @akashap6330 2 ปีที่แล้ว +1

      Who told then she is bad teacher 😒 😂😂

  • @District876
    @District876 5 ปีที่แล้ว +7

    Thanks mam for saving our time and money ...I prefer all of my friends to watch your videoes ..you are the only one who care about us

  • @usmanweb
    @usmanweb 3 ปีที่แล้ว +12

    dear sister,
    you have explained each and everything in a perfect way, earlier I was having a lot's of doubt in "infix in prefix" but you cleared.
    You are the excellent teacher of Data Structure.
    Thank you so much to make a video on this topic.

  • @programmerji3113
    @programmerji3113 4 ปีที่แล้ว +12

    First of all a great great thanks to dear Jenny Teacher.
    I salute her for teaching such a tough topic of DSA in very simple and easy manner.
    When I was in class 6th I use to think how to solve a math expression in Java and C .
    Then when I learnt the INFIX prefix and postfix then I coded my own mathematical Calculation Program in C++.
    Thanks once again mam for your great help by teaching.
    I salute you mam
    ⭐⭐⭐⭐⭐
    Thanks **100000000... Times thank you

  • @kyliemun2681
    @kyliemun2681 5 ปีที่แล้ว +15

    wow it is so clear explanation. i hope you keep making new videos. you saved me !!!!

  • @shreyasambhaikar9600
    @shreyasambhaikar9600 5 ปีที่แล้ว +19

    Mam ur teaching skills are really very good. I understood each and every topics that u taught. Keep it up👍

  • @ramyas355
    @ramyas355 3 ปีที่แล้ว +9

    Thank you so much ma'am 😊
    I found it very helpful
    I was confused when it was thought in my class (online classes) but after watching this video all of my doubts got cleared

    • @akashap6330
      @akashap6330 2 ปีที่แล้ว

      @Sagar . tharki saala 🤣🤣🤣

  • @vigneshdy7151
    @vigneshdy7151 3 หลายเดือนก่อน

    World best teacher 🎉❤ very thankful to you madam our college was do this data structure in just 3 days we won't understand now there will be an exam your videos are very helpful to me thank you so much madam 🎉

  • @testaunni1284
    @testaunni1284 2 หลายเดือนก่อน

    you are the gem....i was not aware of associativity so was getting wrong answer ... now it is clear..thank you very much

  • @khushigarg5397
    @khushigarg5397 3 ปีที่แล้ว +4

    Speechless , what's the explaination, heads off to u ma'am!

  • @ritikasharma2513
    @ritikasharma2513 5 ปีที่แล้ว +8

    Thnkuuu dii for making this video ... seriously Ur way of teaching is sooo attractive which is easily understandable

  • @vatsalpagare6935
    @vatsalpagare6935 4 ปีที่แล้ว +2

    After watching your video of conversion of infix to postfix I was able to write the code on my own using your algorithm.....
    Thanks and present mam😊🙋🏻‍♂️

    • @zinebboukouiss2445
      @zinebboukouiss2445 4 ปีที่แล้ว

      AAYUSH PAGARE hey can you please send me the code if you still have it !! Thank you

  • @csmuffins3588
    @csmuffins3588 3 ปีที่แล้ว +7

    Thank you ma'am!🔥this is the first clip for clearing my doubts for infix conversion🔥👍🏻

  • @introvertzmotivation5632
    @introvertzmotivation5632 4 ปีที่แล้ว +3

    I can't thank you enough ma'am I was struggling with this prefix thing very bad.... Thanks a ton

  • @binduaradhya3514
    @binduaradhya3514 4 ปีที่แล้ว +5

    I have exams in 10 days. I did not understand anything when my clg faculty was teaching....but now after watching your videos data structures has become my favourite subject. Thank you so much ma'am.

  • @anitamatthew4409
    @anitamatthew4409 2 ปีที่แล้ว

    You are the best teacher I have listened to

  • @ritik_ken_001
    @ritik_ken_001 2 ปีที่แล้ว

    Mam you teach very well, I could not understand anything in this subject but when I took your lecture, my doubts were cleared thank you mam.

  • @wajdanakmal8325
    @wajdanakmal8325 2 ปีที่แล้ว +1

    And you are doing great job , i have become your fan from when i saw your first lecture, which was about patterns of C language. Keep going on.

  • @wasit-shafi
    @wasit-shafi 5 ปีที่แล้ว +6

    soon ur going to dominate other CS channels if u continued making more videos...keep it up

  • @arvindkumargupta8856
    @arvindkumargupta8856 2 ปีที่แล้ว +1

    Ma'am you have not written 'U' in the final prefix expression..you have explained very well.. thankyou

  • @mohamedkanu66
    @mohamedkanu66 4 ปีที่แล้ว +1

    Thanks mam. Minor mistake in d stack conversion to prefix. It left out the U after reversing but it's ok. You are super excellent mam. You have saved my life for good

  • @kartiksolanki4156
    @kartiksolanki4156 3 ปีที่แล้ว +1

    Mam,you are a magician because you fill concept in our mind in only a video ❤️

  • @santukapri2409
    @santukapri2409 2 ปีที่แล้ว +3

    I think after watching this video there is no doubt for any student like me on this important topic.

  • @tendaindagurwa3605
    @tendaindagurwa3605 4 ปีที่แล้ว +1

    thanks for your contributions. i love you Ma'am. keep continue with your hard work, and you are helping me a lot. God bless you.

  • @dhirajkumar9264
    @dhirajkumar9264 ปีที่แล้ว +3

    Ma'am It seems like data structures is more easier than class 8 maths for me ..The way u are explaining the concepts is just awesome...

  • @debjitdey4165
    @debjitdey4165 ปีที่แล้ว +2

    Thank you ma'am for this, Tomorrow is my DSA exam, thank you for the last minute preparation

  • @bhanuprakash6915
    @bhanuprakash6915 2 ปีที่แล้ว +1

    Mam,you make my life so easy in data structures
    Thanks a lot mam..... ❣️♥️♥️

  • @AMRUTHJSHETTY
    @AMRUTHJSHETTY 3 ปีที่แล้ว

    MAM YOU ARE THE BEST TEACHER OF MINE YOU MADE MY LIFE EASIER

  • @elatedvids7354
    @elatedvids7354 3 ปีที่แล้ว

    thank you for helping me. I followed your many videos. God BLESS YOU.

  • @khushipurwar8101
    @khushipurwar8101 4 ปีที่แล้ว

    Your teaching way is superb.. I understand easily

  • @radadiyajenis5150
    @radadiyajenis5150 3 ปีที่แล้ว +1

    Mam ap hamare valmiki guru ho
    Apke lecture dekh k me dsa topper ho gaya

  • @ashutoshshukla5581
    @ashutoshshukla5581 2 ปีที่แล้ว +1

    at 13:52 you missed "U" in the expression. Anyways nice explanation ma'am!

  • @mayurkatarmal2672
    @mayurkatarmal2672 3 ปีที่แล้ว

    Mam, these lectures are best! I was feared of this topic. But you have made it very easy. Thanks a lot

  • @sadiakiran6695
    @sadiakiran6695 4 ปีที่แล้ว +1

    MA'AM IT'S SPLENDID!! THANK YOU SO MUCH

  • @srijitanitamajumdar5904
    @srijitanitamajumdar5904 4 ปีที่แล้ว +22

    Ma'am, in your previous lectures you had taught that if both the incoming and the 'top-of-the-stack' operators have the same precedence and thereafter associativity of 'Left-right', then we need to pop the top of the stack before storing the incoming operator. But here in the 8th step, you pushed the incoming operator instead.

    • @dominicpeng8802
      @dominicpeng8802 4 ปีที่แล้ว +10

      that should be the infix to postfix case because in the prefix case you are scanning the string reversely which leads to reversed associativities rules

    • @gracenote108
      @gracenote108 4 ปีที่แล้ว +4

      @@dominicpeng8802 So I'm actually wondering the samething. Other guides say that we should follow the postfix style operator associativity rules since we already reversed the expression.

    • @ZahidHasan-sv2sh
      @ZahidHasan-sv2sh 4 ปีที่แล้ว

      what if right to left associativity in case of infix to prefix

    • @matthewadams4097
      @matthewadams4097 3 ปีที่แล้ว +4

      Guys, basically if you're just doing infix->postfix you just loop the condition
      while (precedence(operator) top)
      pop
      finally push
      if doing infix->prefix, reverse the string and then do the same process as postfixing but instead the condition for operators is
      while (precedence(operator) < precedence(operator at stack->top)
      pop
      finally push
      (At the end reverse again)
      Hope this helped

  • @gueshteklu8624
    @gueshteklu8624 7 หลายเดือนก่อน

    Thanks My Lovley Teacher For Your Great Contribution To develop My Attitude In DS!!!!!!

  • @janhavipimplikar6048
    @janhavipimplikar6048 3 ปีที่แล้ว +2

    Amazing video with such a simple and articulate explanation... Keep it up ma'am! 💯

  • @RaviTeja-of2gp
    @RaviTeja-of2gp 5 ปีที่แล้ว +4

    Mam while explaning please give synonyms for prefix , postfix, and infix like for post fix reverse polish.When anyone see a new name they think that they don't know the concept.In exam they will use synonyms mostly.

  • @rbrothers1337
    @rbrothers1337 3 ปีที่แล้ว

    Mam, your teaching style is amazing

  • @AbdulsamadTajudeen
    @AbdulsamadTajudeen ปีที่แล้ว

    thank you so much ma'am had data structure exams and will your help I was able to pass 20 marks for one question

  • @vakhariyajay2224
    @vakhariyajay2224 2 ปีที่แล้ว +2

    Thank you very much. You are a genius. 👍👍🔝🔝👌👌

  • @user-oc8cr1ib2u
    @user-oc8cr1ib2u 4 ปีที่แล้ว

    thank u so much ma'am i really like ur way of teaching and finally understood both of the conversations; infix to postfix and prefix

  • @asthatrip2028
    @asthatrip2028 5 ปีที่แล้ว +1

    Ma'am aap ki way of teaching bahut acchi hai please aur bhi subjects le ke aaiye .... For ugc net exam

  • @umangjain2893
    @umangjain2893 4 ปีที่แล้ว +7

    Ma'am in flow you do one mistake in the final result of prefix you miss the U element

  • @HasakelumKavindu
    @HasakelumKavindu 3 หลายเดือนก่อน

    Thanks maam you are a good teacher.

  • @enter10mentchannel26
    @enter10mentchannel26 3 ปีที่แล้ว +4

    A small mistake ma'am in this video. After getting final answer using algorithm you forgot to write "U" i.e. in the end it will be "OPWUVTQ" but you have written"OPWVTQ".It's somewhere between 13:00 - 15:00

  • @naitikrathor1808
    @naitikrathor1808 3 ปีที่แล้ว +2

    Ma'am prefix for this infix expression" K+L-M*N+(O^P)*W/U/V*T+Q " will be "+K-L+*MN+*^OP/W/U*VTQ "..... not that what you taught.........pls let me know if I am wrong....

    • @aaryasrigurudattadarsi1705
      @aaryasrigurudattadarsi1705 10 หลายเดือนก่อน

      but javaTutorialPoint says the same as mam said whereas some online converters are giving the ans you said

  • @rbrothers1337
    @rbrothers1337 3 ปีที่แล้ว

    Mam , you are a really good teacher

  • @vaibhavsingh2209
    @vaibhavsingh2209 2 ปีที่แล้ว

    Mam I love your teaching style

  • @divyatayade4993
    @divyatayade4993 4 ปีที่แล้ว

    You are best teacher forever 👍👍

  • @shrur3527
    @shrur3527 3 ปีที่แล้ว +1

    Wish u all success n happiness in life mam

  • @adityajha9843
    @adityajha9843 9 หลายเดือนก่อน

    MADAM JI , I REALLY LIKE THE WAY YOU TEACH US ALL AND THE CONTENT IS JUST AMAZING HATS OFF TO YOUR HARD WAR
    .

  • @ShivaniSingh-hs9et
    @ShivaniSingh-hs9et 3 ปีที่แล้ว

    Ma'am your explanation is unbelievable.... thanks a lot ma'am 🙏❤️

  • @GoodVibes-xp6pv
    @GoodVibes-xp6pv 3 ปีที่แล้ว

    Finally, cleared the concept !! 👏🏻 only U is left 🤭🤭 to write as last after scanning all ! But it’s totally understanding

  • @shekharchaudhary9970
    @shekharchaudhary9970 3 หลายเดือนก่อน

    Mam.. Out teaching teaching techniques are as beautiful u are

  • @nandinikumari2185
    @nandinikumari2185 3 ปีที่แล้ว

    Mam this video is really helpful now I understand this properly thanks for this video

  • @gargsaumya20
    @gargsaumya20 4 ปีที่แล้ว +1

    Mam, your teaching skill is awesome...
    Can you please give the code in C of the conversion....

  • @syedjawahar8542
    @syedjawahar8542 3 ปีที่แล้ว +4

    when writing final expresion - you have missed 'U' ie QTVUW .... and the same is missed in final reverse string also (ie actual prefix expression)... I dont see any one commenting this...

    • @vikasbagri1225
      @vikasbagri1225 3 ปีที่แล้ว

      Didnt see that... Gud

    • @69upasonabiswas88
      @69upasonabiswas88 3 ปีที่แล้ว

      no one is commenting bcz they know that it's a silly mistake not a conceptual or logical mistake.. that's why

  • @muztahidhassan7165
    @muztahidhassan7165 2 ปีที่แล้ว

    Mam, your lecture is very helpful. But you missed the 'U' operand at 13:59. Thank you.

  • @mohtasimhossain3741
    @mohtasimhossain3741 8 หลายเดือนก่อน

    Thank you very much ma'am.
    Best wishes for you always.❤❤

  • @medhaviagarwal8156
    @medhaviagarwal8156 3 ปีที่แล้ว

    Your method is very nice mam. I understood the concept clearly♥️

  • @namangokharu2069
    @namangokharu2069 4 ปีที่แล้ว +2

    I think mam did a mistake somewhere, correct answer in prefix is :
    +K-L+*MN+*^OP/W/U*VTQ ... Thankyou mam.

    • @devplays3200
      @devplays3200 4 ปีที่แล้ว

      for a second i thought u are gving her slangs 😂😂

  • @dineshkumarsingh8079
    @dineshkumarsingh8079 2 ปีที่แล้ว

    You are amazing mam...i am watching this just before exam day

  • @6020Bhupendrasingh
    @6020Bhupendrasingh 2 หลายเดือนก่อน

    Thank you very much mam I was making mistake in due to associativity, Thank you I got it now

  • @Mk-lh3vj
    @Mk-lh3vj 5 ปีที่แล้ว +2

    Thanks mam i like your teaching 👌👌

  • @manukarthikeya4560
    @manukarthikeya4560 2 ปีที่แล้ว

    mam u forgot to write the u in the first complete prefix check once mam. and thank you for explaining these concepts nicely ..

  • @ThinkFortuneTamil
    @ThinkFortuneTamil 4 ปีที่แล้ว

    Wow wonderful mam , we all need great teacher like u mam

  • @wajdanakmal8325
    @wajdanakmal8325 2 ปีที่แล้ว +102

    In the final expression and reverse of expression, you have forgotten the "U" lying between the W and V in the expression.

    • @piyushbedre3769
      @piyushbedre3769 ปีที่แล้ว +9

      mam is always right

    • @ghimasree2607
      @ghimasree2607 ปีที่แล้ว +6

      Yes she forgot the U lying b/w "w"&"v"

    • @novinjeno7981
      @novinjeno7981 ปีที่แล้ว +20

      Instead of focusing on that U that maam has left , focus on you .she made you understand the concept that is why you are able to point it out.

    • @sv798
      @sv798 ปีที่แล้ว +2

      True

    • @wajdanakmal8325
      @wajdanakmal8325 ปีที่แล้ว +10

      @@novinjeno7981 no doubt !, I appreciates her for the job she has been doing since many before.

  • @uzairahmed2398
    @uzairahmed2398 3 ปีที่แล้ว

    now i can get higher marks on my next quiz InshaAllah (thank you for this tutorials)

  • @sandeepkumarthakur7368
    @sandeepkumarthakur7368 4 ปีที่แล้ว

    Thank you ma'am I wish you were the faculty of our uni..

  • @akshaysuman4328
    @akshaysuman4328 5 ปีที่แล้ว +1

    Upload more mam.you are fabulous! No one can match u in ordert to explanation.

  • @nazmulfahim7962
    @nazmulfahim7962 5 ปีที่แล้ว +4

    wow ..tomorrow is my exam ..and today I get the video

  • @SumitKumar-mv5gp
    @SumitKumar-mv5gp 8 หลายเดือนก่อน

    There is a slight mistake in the answer solved by stack method,
    ++-+KL*MN*//*^OPWUVTQ
    Mam forget "U" in the final answer.
    And, No doubt its a great video.

  • @DK-Tank01
    @DK-Tank01 4 ปีที่แล้ว +1

    Thanks a lot really enjoyed a lot🥰🥰🥰🥰🥰 the teaching really! Very helpful......

  • @aliayeshpervez4787
    @aliayeshpervez4787 4 ปีที่แล้ว

    you are such a nice teacher...love you mam

  • @ShumailaQamerBajwa
    @ShumailaQamerBajwa 3 ปีที่แล้ว +4

    There was one rule not discussed in this example, what if incoming operator has same precedence as top of the stack, however the associativity is right to left?

  • @sarank4465
    @sarank4465 ปีที่แล้ว +7

    I think there is a mistake while representing. Operators of same precedence but different associtivity, leads to pop() popping the existing operator. And the other online converters give another output for this question

  • @darshanpatidar3155
    @darshanpatidar3155 4 ปีที่แล้ว +1

    Content is very clear keep it up

  • @dileepkumar5839
    @dileepkumar5839 5 ปีที่แล้ว +7

    Mam it would b great if u make a proper playlist topic wise.. It's difficult to understand the sequence of ur videos..!

    • @JennyslecturesCSIT
      @JennyslecturesCSIT  5 ปีที่แล้ว +2

      Thanks alot for your nice suggestion

    • @zaheerkhan45
      @zaheerkhan45 5 ปีที่แล้ว

      PLEASE CAN YOU GIVE YOUR #

    • @dileepkumar5839
      @dileepkumar5839 5 ปีที่แล้ว +1

      @@JennyslecturesCSIT thanks alot mam.. After listening to ur videos n then studying the textbook again, gives us more clarity which I didn't have 2 months back.. Respect from Hyderabad 😘😘🙏🙏🙏❤❤

    • @arbazmania3529
      @arbazmania3529 4 ปีที่แล้ว

      Yaha reply krdiya comment ka

  • @vasachisenjubean5944
    @vasachisenjubean5944 4 ปีที่แล้ว

    genuine teacher #respect

  • @sumitsinghGYMvids
    @sumitsinghGYMvids 3 ปีที่แล้ว +8

    Feeling sad for 'U' in the final expression😂.....jokes apart....nice explanation ma'am....thank you..

  • @subhajitpaul304
    @subhajitpaul304 3 ปีที่แล้ว

    very much thanks mam.u r very helpfull.u clear my all doubt

  • @yogeshborhade5533
    @yogeshborhade5533 3 ปีที่แล้ว

    Thanks for the explanation. But you forgot to write U in the last two expression while converting infix to prefix using stack. But no problem, we have understood the concept. Once again thanks for the video.👍🙏

  • @vishnupanchal5944
    @vishnupanchal5944 3 ปีที่แล้ว

    Mam , you are very good teacher and smart good looking
    Clear all dout

  • @anandtripathi4068
    @anandtripathi4068 ปีที่แล้ว

    I could watch u all day, ❤

  • @dukhdard-ik3us
    @dukhdard-ik3us ปีที่แล้ว

    I like your videos mam. plz.............. plz make more videos my friends are your fans☺☺☺☺☺☺☺

  • @gargsaumya20
    @gargsaumya20 4 ปีที่แล้ว

    Mam, your teaching skill is awesome...
    Can you please give the code in C of the conversion....

  • @RUPAKUMARI-di4kl
    @RUPAKUMARI-di4kl ปีที่แล้ว

    Very very helpful class ek bar me samjh aa gya

  • @anishmanandhar1203
    @anishmanandhar1203 3 ปีที่แล้ว +2

    I find this completely wrong as to treat the reverse expression as if working with postfix expression and finally reversing the expression this
    I got :
    +k-l+*mn+*^op/w/u*vtq

  • @maulikvaghela2971
    @maulikvaghela2971 8 หลายเดือนก่อน +2

    Above Infix equation to prefix conversion start from 05:26

  • @sagarg8953
    @sagarg8953 4 ปีที่แล้ว +1

    Thank-you...U teach awesome 🙂🙏

  • @rajankesharwani9486
    @rajankesharwani9486 3 ปีที่แล้ว

    Sorry for telling , The Expected output is not match with this output , But teaching style and knowledge are very professional.

  • @modulusmod4111
    @modulusmod4111 4 ปีที่แล้ว +1

    2nd one is damn fast, thanks for these awesome tutorials

  • @LaxmiKumari-pc9rr
    @LaxmiKumari-pc9rr 4 ปีที่แล้ว

    Thank u so much maam
    You are best teacher 👍

  • @javedquantum2618
    @javedquantum2618 3 ปีที่แล้ว

    Thanks mam for such a great work 🙏

  • @_commando9996
    @_commando9996 2 ปีที่แล้ว +1

    🇮🇳 "जय हिंद" #Ma'am! Good 🌞Afternoon. #Thank's for Nice information 😎 . ..

  • @soumitradas3714
    @soumitradas3714 3 ปีที่แล้ว

    Thank you very very much ma'am, it really helped a lot. Thanks a lot.