If Else Conditionals & Switches in JavaScript | JavaScript Tutorial In Hindi #8

Поділитися
Вставка
  • Опубліковано 27 сер 2024
  • I have an updated version of JavaScript course going on. This Ultimate JavaScript course is being supplied with handwritten notes and I highly recommend the latest course over this.
    Must watch the updated course here: • JavaScript Tutorials f...
    ►JavaScript Tutorial For Beginners In Hindi Playlist - • JavaScript Tutorials I...
    ►Source Code + Other Material - codewithharry....
    This video is a part of my JavaScript In Hindi Course. JavaScript is a high-level, interpreted programming language that conforms to the ECMAScript specification. JavaScript has dynamic typing, prototype-based object-orientation, and first-class functions.
    Alongside HTML and CSS, JavaScript is one of the best and most demanded technologies of the World Wide Web. JavaScript enables interactive web pages and is a crucial part of web applications. The vast majority of sites use it, and major web browsers have a dedicated JavaScript engine in order to execute it.
    As a multi-paradigm language, it supports event-driven, functional, and imperative programming fashion. It has APIs for dealing with text, arrays, regular expressions, and the DOM, but the language itself does not include any I/O, such as networking, storage, or graphics facilities. It relies upon the host machine environment in which it is embedded to provide these features.
    ►Click here to subscribe - / @codewithharry
    Best Hindi Videos For Learning Programming:
    ►Learn Python In One Video - • Learn Python In Hindi ...
    ►Learn JavaScript in One Video - • JavaScript Tutorial
    ►Learn PHP In One Video - • Learn Php In One Video...
    ►Machine Learning Using Python - • Machine Learning Tutor...
    ►Creating & Hosting A Website (Tech Blog) Using Python - • [Hindi] Web Developmen...
    ►Advanced Python Tutorials - • Intermediate/Advanced ...
    ►Object Oriented Programming In Python - • Object Oriented Progra...
    ►Python Data Science and Big Data Tutorials - • Python Data Science an...
    Follow Me On Social Media
    ►Website (created using Flask) - www.codewithha...
    ►Facebook - / codewithharry
    ►Instagram - / codewithharry
    ►Personal Facebook A/c - / geekyharis
    Twitter - / haris_is_here

КОМЕНТАРІ • 186

  • @CodeWithHarry
    @CodeWithHarry  2 роки тому +6

    I have an updated version of JavaScript course going on. This Ultimate JavaScript course is being supplied with handwritten notes and I highly recommend the latest course over this.
    Must watch the updated course here: ua-cam.com/play/PLu0W_9lII9ahR1blWXxgSlL4y9iQBnLpR.html

  • @aashishjoshishorts
    @aashishjoshishorts 3 роки тому +12

    My first programming language

  • @AmanKumar-ng7gj
    @AmanKumar-ng7gj 5 років тому +41

    and ...thank you so much. by your continuous effort we are learning in very easy way, free of cost.
    Thank you Harry bhai..love you..♥️

  • @iamaniketkr
    @iamaniketkr 4 роки тому +15

    Best JavaScript Tutorial On UA-cam.
    Thank you Code With Harry 😃♥️

  • @krrishchaudhary1085
    @krrishchaudhary1085 3 роки тому +17

    11:30
    Question Solved Sir....
    Answer :
    let age = 18;
    canVote = true;
    if(age >= 18 && canVote ) {
    console.log("You can vote");
    }
    else if(age

  • @AmitKumar-oz1ti
    @AmitKumar-oz1ti 3 роки тому +1

    Wa Harry Bhai mst video bnayi apne,

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

    Awesome tutorial bhai, i was new in programming and this is my first launguage after html and css, and i can easily access notes and all, wish me luck for the long journery,, allah hafizz

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

    you are awesome.......i am a begginner and now i am learning very fast .........thanks bro

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

    harry bhai, one short advice if new audience or new programmer are viewing this video, please pause and ask to take notes or make digital notes otherwise its seems that audience will learn JS by just watching the tutorial.

  • @smartcomputring1034
    @smartcomputring1034 3 роки тому +3

    sir thank you so very much 😃♥️

  • @Codingsudo
    @Codingsudo 3 роки тому +1

    Superb videos sir hats of to u

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

    harry bhai, Hacktoberfest ke bare me btane ke liye shukriya
    mai class 9 me padti hun aur maine T shirt jeet li.....................................................................

  • @ayushtrivedi1513
    @ayushtrivedi1513 3 роки тому +6

    const a=12;
    const b=12;
    const c=12;
    if(a==b && a==c && b==c ){
    console.log('equivalent triangle');
    }
    if(a==b ){
    console.log('isosceles triangle');
    }
    else {
    console.log(' scalene triangle');
    }

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

      Iska O/P isoceles triangle ainga na ?

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

      @@aavezshaikh143 equivalent and isosceles dono aaenge.

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

    perfect explanation of if else and switch ..

  • @sarikaprajapati2493
    @sarikaprajapati2493 2 роки тому +5

    11:30
    let room1 = 23;
    let room2 = 'Sam';
    let stu = true;
    if((room1 == 23 || room2 == 'Sam')&& stu ){
    console.log('Printed all terms')
    }
    else{
    console.log('Not Printed');
    }

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

    Thanks

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

    आप इतना सारा फ्री में सिखा रहे है मेरे पास पैसे नहीं आपको देने को लेकिन मै आपके ads पर क्लिक नहीं करता हूँ ताकि आपको थोडा revenue generate हो सके
    love you harry bhai for this type learning for free
    proud to be an indian
    jai hind jai bharat

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

    Thank You very much bro.

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

    Thank you so much sir for your high efforts

  • @nibeditajena1042
    @nibeditajena1042 3 роки тому +1

    you are coding master!!!):):-

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

    Thanks a lot Bhaiyaa

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

    Thank you bhai ❤️

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

    Great video🎺🎺🎺

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

    Thanks bro❤❤

  • @RohanDasRD
    @RohanDasRD 5 років тому +30

    Js is so easy

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

    Thanks bro ♥️

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

    best hai Sir jee

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

    Thanx Harry

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

    Data structure and algorithm plzzzzzzz

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

    Thnx

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

    love you bro!

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

    var a=10
    var b =15
    console.log(ab);
    asked in interview , Do this simple ques also

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

    Lub you😍😍😍

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

    I was thinking that I know 'if else " and so can I skip this video, but I have watched and as I expect I learn so many things. you are amazing.☺

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

    Bhai operators ke baare me to btaya ni apne is poore course me?

  • @adarshkhatri993
    @adarshkhatri993 3 роки тому +1

    Harry bhai makes everything easy..😊

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

    💯💯💯

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

    Harry bhai ek playlist "code with SEO "ho jaye please sir

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

    Thank you Harry bhaiyya

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

    zabardast tutorials

  • @himanshuharsh12tha28
    @himanshuharsh12tha28 3 роки тому +1

    Congratulations on 1 million subscribers

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

    some one please reply : there are situations we need to use multiple if (no else if ) and one else , in that condition to execute else condition all the if condition must be false at once

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

    thank you so much sir

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

    Done

  • @aryansharma8794
    @aryansharma8794 3 роки тому +1

    Amazing tutorial sir

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

    Sir data structure aur algorithm start kab karenge...

  • @rrv8161
    @rrv8161 5 років тому +1

    I am yours big fan 💕💗💛💕💛💞🧡💕🧡💞🧡💕💛🧡💚🧡💕🧡and 30ty liker

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

    04:50 - ===
    08:41 - typeof variable

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

    if anyone is having problem in switch then dont worry it is just for ur knowledge u will often use if else

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

    harry bhai agar possible ho to sql ki bhi playlist banao

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

    doing this after learning css

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

    Hello Harry bhai please shall and bash language ke upar Ek video bana do...

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

    good sir ji

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

    Bro aapne es video me comparison operation ka use Kiya hai lekin es series me esse pehle comparison operator ke baare me bataya nahi hai

  • @tilak4009
    @tilak4009 3 роки тому +1

    From where did you learn java script ?

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

    Done done again

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

    11:41
    age = 15;
    if (age == 15 || age < 15) {
    console.log('you age not aligible')
    } else if (age == 100 || age > 100) {
    console.log('your are outdated God is waiting for you')
    } else {
    console.log('You are aligible')
    }

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

    nice harry bhiya

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

    I have made default using template literals

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

    Thank u so much bhaiya. Best channel to learn.

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

    11:29
    const marks_1 = 92;
    const marks_2 = 75;
    const marks_3 = 88;
    if (marks_1 && marks_2 && marks_3 >=80) {
    console.log("Your result is excellent");
    }
    else if ((marks_1 && marks_2) || marks_3 >=80){ console.log("Your mark_1 & mark_2 is good");
    }
    else if (marks_1 || (marks_2 && marks_3 >=80)){
    console.log("Your mark_2 & mark_3 is good");
    }
    else {
    console.log("Your result is poor!!!");
    }
    //output
    Your result is excellent

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

    love to learn

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

    Thank you for providing free vedio. You are requested to provide chatsheet of all the vedios on nominal payment.

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

    If else and switch condition work same?

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

    Thank u for these videos Harry bhai....Great videos and Great contents

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

    const age = 18;
    const havelicense = true;
    const alcohollevel = 0.1;
    if (age>=18 && havelicense && alcohollevel

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

    var age = 8;
    switch (age){
    case 18:
    document.write('You are 18');
    break;
    case 28:
    document.write('You are 28');
    break;
    case 38:
    document.write('You are 38');
    break;
    default:
    document.write('Age unknown');
    break;

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

    var ex=34
    if(typeof ex !== "undefined" && ex>31 &&ex

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

    if(testdrive && age=60)
    {
    console.log("you cannot drive");
    }
    else if(testdrive && 18

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

    I would like to see you on the sundeep maheshwari stage ....

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

    thank you so much harry bhai for your hardwork

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

    Harry Bhai ye ap console.log me sub print kar rhe ho ye sb webpage pe kese print Hoga ?

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

    Aapne Jo c language ke tutorial upload kiye the kya woh a to z C hai

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

    Could you make a video on adding cut scenes in pygame

  • @achainsanei4714
    @achainsanei4714 5 років тому +1

    mujhe be ek Dil bro ♥️♥️♥️♥️♥️

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

    If we want to use propmt for age

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

    sir please django ka social app bna dijiye, ek video mai

  • @kk-uw3wf
    @kk-uw3wf 4 роки тому

    Harry bhai default me bhi break hota hai kya?

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

    Before go for conditions and datatypes , you should explain all type of operators first in the second video itself.

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

    1 million subscribe from myself

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

    great sir ji.

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

    thank you harry almighty

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

    Bhai plz es6-7 bhi cover krna course me and Dom bhi plz

  • @kk-uw3wf
    @kk-uw3wf 4 роки тому

    Harry bhai switch program me default ke bad break kiw lagay hai

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

    Thankyou Harry Sir ❤❤

  • @DaljitSingh-wq9kj
    @DaljitSingh-wq9kj 3 роки тому

    Harry bhaii.... JavaScript k notes kaha milege ... Handwritten.... Plzzz inform me

  • @a.k.rprogrammer3784
    @a.k.rprogrammer3784 2 роки тому

    const vari = "undefined"
    if(typeof vari === 'undefined'){
    console.log('Vari is defined')
    }
    else{
    console.log("Vari is not defined")
    }
    why the output is coming vari is not defined please explain anyone?

  • @NarutoUzumaki-fy6fo
    @NarutoUzumaki-fy6fo 2 роки тому

    14:11 main kauns extension use kiya hain

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

    Bhai function in JavaScript pe video banao

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

    Sir, में ws2812b rgb led strip को push बटन से control करना चाहता हूँ।
    जब एक बार push बटन press करे तो led strip का color red हो जाय और दूसरी बार उसी बटन को press करने पर green हो जाये।
    मेरा कहने अर्थ सिर्फ एक push बटन को 7 बार press करने पर पूरी स्ट्रिप का कलर change जो जाए। please इस पर एक वीडियो बनाओ।

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

      Sir मुझे programming नही आती। क्या आप इसको modify कर सकते हो जैसा कि ऊपर कमेंट में request की है।
      #include
      #define Num_Strip1 60
      #define Button 8
      CRGB Strip1[Num_Strip1];
      int Program = 0;
      int maxProgram = 2;
      int Num = 0;
      int Run = 0;
      int ButtonDelay = 200;
      int Program0Delay = 100;
      int Program1Delay = 100;
      //int Program2Delay = 10;
      unsigned long ButtonTime = 0;
      unsigned long DelayTime = 0;
      void setup()
      {
      pinMode(Button, INPUT_PULLUP);
      FastLED.addLeds(Strip1, Num_Strip1);
      Serial.begin(9600);
      }
      void loop()
      {
      if(digitalRead(Button) == LOW && millis() - ButtonTime > ButtonDelay)
      {
      ButtonTime = millis();
      Num = 0;
      Run = 0;
      if(Program < maxProgram)
      {
      Program++;
      for(int Num = 0; Num < Num_Strip1; Num++)
      {
      Strip1 [ Num ] = CRGB (255, 0, 0) ; // Red
      }
      FastLED.show();
      }

      else
      {
      Program = 0;
      for(int Num = 0; Num < Num_Strip1; Num++)
      {
      Strip1 [ Num ] = CRGB (0, 255, 0) ; // Green
      }
      FastLED.show();
      }

      }
      }

  • @soumyaranjannanda1815
    @soumyaranjannanda1815 3 роки тому +3

    Let age = 16 :
    Let adult = false:
    If (age==18 && adult) {
    Console.log(you are an adult of 18yrs. );
    } else if (age==18 || adult) {
    Console.log('You are either adult or below 18 ');
    }else {
    Console.log('baccha h re tu....');
    Quiz answer.....😁
    Thanks harry bhai 🔥❤️☺️

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

    ek dikkat he esse sikh toh jaenge lekin jo agar website ya apps baane me thodi dikkat dsega jese ye kiss tarah se estemal kare

  • @rosonerri-faithful
    @rosonerri-faithful 3 роки тому +2

    11:35 Solve:
    var hasAdhar=true;
    var age=20;
    var nationality = "Indian";
    if((hasAdhar)&&(age > 18) && nationality =='Indian'){
    console.log("Eligible to Vote");
    }
    else{
    console.log("Sorry! Ineligible!");
    }
    //Output:Eligible to Vote

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

    Your qualifications plz

    • @geeli_puppy_.
      @geeli_puppy_. 3 роки тому +1

      he is an nasa certified HTML hacker and he is from iit kharagpur

  • @LuckyGupta-zu2oi
    @LuckyGupta-zu2oi 4 роки тому

    Plz tell me in details about form validation

  • @mdasif-ze7bc
    @mdasif-ze7bc 2 роки тому

    //Do not declare variable marks.
    //Write your code below this line.
    if (marks >90) {
    console.log("AA")

    }
    else if (marks >80 && marks70 && marks60 && marks 50 && marks 40 && marks30 && marks

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

    bro u have confused it by doing else if, equals to, double equals to, and all in the same programme.

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

    let age = 15
    let weight = 65
    if(age>18 && weight18 && weight

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

    Please test this one:
    // Students having (AGE > 17 OR HEIGHT > 5.5) AND (GRADE > 10) can join a party.
    let age = prompt("Write your AGE: ");
    let height = prompt("Write your HEIGHT (in feet): ");
    let grade = prompt("Write your GRADE: ");
    if ( (age > 17 || height > 5.5) && (grade > 10) ) {
    console.log("Welcome! You can Join.")
    } else {
    console.log("Sorry! You cannot Join.")
    }

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

      Without Prompt:
      // Students having (AGE > 17 OR HEIGHT > 5.5) AND (GRADE > 10) can join a party.
      let age = 17;
      let height = 5.6;
      let grade = 13;
      if ( (age > 17 || height > 5.5) && (grade > 10) ) {
      console.log("Welcome! You can Join.")
      } else {
      console.log("Sorry! You cannot Join.")
      }

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

    const age = 17;
    const Experience = true;
    const qualification = true;
    if (age=18 || Experience || qualification) {
    console.log(" you can apply for this job");
    }
    else{
    console.log("you are not qualified for this seesion or to move nest session and go to work hard to get good numbers then selected ");
    }