Exception Handling in c++ | Part-2/3 | Try, Catch & Throw | OOPs in C++ | Lec-47 | Bhanu Priya

Поделиться
HTML-код
  • Опубликовано: 8 сен 2024
  • what is the use of try, catch and throw keywords, how to construct the try and catch block, how to throw an exception in detail with example.
    Please Like, share and subscribe: / @education4uofficial
    for more related videos

Комментарии • 17

  • @riyasaju3825
    @riyasaju3825 3 года назад +1

    Thanks a lot

  • @memepitchh
    @memepitchh 2 года назад +1

    some corrections in program--
    #include
    using namespace std;
    int main()
    {
    int a=10, b=0, c;

    try
    {
    if (b==0)
    throw "division by zero is not possible";
    c=a/b;
    }
    catch (char const*Excp)
    {
    cout

  • @treeofknowledge1345
    @treeofknowledge1345 4 года назад

    great method madam

  • @samadmd4985
    @samadmd4985 5 лет назад

    Good one.. better to explain with practical example by excute

  • @3thrisha869
    @3thrisha869 Год назад

    Tq mam

  • @jesusprayer8969
    @jesusprayer8969 5 лет назад +1

    Mam why we can use using namespace in cpp...

  • @y.kadharhussan1892
    @y.kadharhussan1892 5 лет назад

    here division by sero is not possible is not displayed in output

  • @tarunbhogapurapu9483
    @tarunbhogapurapu9483 4 года назад

    Are you a lecture

  • @chirag8503
    @chirag8503 3 года назад

    stop watching from 10:10 whole code error ..mam pls check before u post

    • @saisreekar4425
      @saisreekar4425 2 года назад +3

      here's the corrected program
      #include
      using namespace std;
      int main()
      {
      int a=10,b=0,c;
      try{
      if(b==0)
      {
      throw "impossible";
      c=a/b;
      }
      }
      catch(char const*ex)
      {
      cout