Basics of variables and constants in javascript

Поделиться
HTML-код
  • Опубликовано: 21 авг 2024
  • Welcome to a youtube channel dedicated to programming and coding related tutorials. We talk about tech, write code, discuss about cloud and devops. That’s what we do all day, all year. We roll out a lot of series and videos on our channel.
    All the learning resources such as code files, documentations, articles and community discussions are available on our website:
    chaicode.com/
    You can find our discord link, github link etc on the above website.
    Twitter/X link: x.com/hiteshdo...
    Discord link: hitesh.ai/discord
    Learn React with 10 projects: • Let's learn react from...
    Learn Docker: • A practical guide on D...
    Learn Kubernetes: • Complete Kubernetes Co...
    How does a browser works: • How does a browser wor...
    How nodejs works: • How node JS works | En...
    Learn Redux-toolkit: • Learn Redux Toolkit in...
    Learn NextJS: • Nextjs Full stack course
    Learn Typescript: • Why to learn Typescript
    Learn Javascript: • Welcome to new JavaScr...
    Learn React Native: • React Native Mastery: ...
    Learn Zustand: • React state management...
    Learn Golang: • How to get started wit...

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

  • @HiteshCodeLab
    @HiteshCodeLab  6 лет назад +9

    Videos in a proper sequence and with discussion support are available at my website (of course free). It's easier for me to address issues at one place, instead of drilling into every video. A quick word, please help others in the discussion too.
    courses.learncodeonline.in/learn/Javascript-for-2018-developer

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

      Hi Hitesh, I'm loving your channel, I've decided to start with JavaScript and when i need a break, Java itself, so i'll learn both at the same time kind of.
      I have a simple question I'd love an answer too, with Javascript or Java, is it possible for me to make just a tiny little desktop program that you can click, that when clicked it can automatically open say, Google Chrome search window for you? I want to do this as nmy firsat program, simple little program, click it, in the little box it says "Connect", i click it, and the program goes and open google chrome for me as i have it set like that in the code. I just want to know if it's possible? Thanks!

    • @gurjeetsingh-qp4wp
      @gurjeetsingh-qp4wp 4 года назад

      let ram having money = 100
      let money given to ram by sita = 25
      let money given to ram by gita = 29
      let total money ram have = ram having money + money given to ram by sita + money given to ram by gita
      I have tried this code for practice, but it's not working. Can you please tell me why it isn't working ?

    • @gurjeetsingh-qp4wp
      @gurjeetsingh-qp4wp 4 года назад

      ohkk. sorry. I got that. camel case worked for me. Thanks alot hitesh sir.

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

      Sir can you please tell me how can i use cmd on windows I tried but couldn't

  • @gwalaniarun
    @gwalaniarun 6 лет назад +8

    Thanks for RAIN OF JAVASCRIPT
    So much video in one day..

  • @salwacoding5661
    @salwacoding5661 4 года назад +1

    Your voice tone is just so encouraging ,Thank You Sir.

  • @faizKhan-wn5fr
    @faizKhan-wn5fr 6 лет назад +10

    Hey guys hitesh back again with another episode of JavaScript we gonna break the record uploading videos in a day 😁

  • @shubhamchannagire1370
    @shubhamchannagire1370 6 лет назад +2

    Love the way u explain...m beginner and its just perfect for me. Thanks

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

    Simply One Word "OUTSTANDING" your videos are GREAT and the way you teach is amazing ....SIR THANKS VERY VERY MUCH

  • @pile333
    @pile333 6 лет назад

    Dude, you're an incredibly good teacher.

  • @marnix_antil
    @marnix_antil 6 лет назад

    Awesome tutorials sir you are doing so much for the people who don't even have enough money to buy tutorials on your website .This series also helps those who want to demo of your tutorials thank you so much

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

    Thanks in a million! Great teachers are hard to find.

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

    I know JS is smart language and a semicolon is optional in it but I think in my opinion using a semicolon is good practice until you are not using PUG instead of HTML, SASS instead of SCSS and JS, PYTHON, KOTLIN instead of JAVA, C,C++ or anything else ,where semicolon is mandatory. :)

  • @NITISHKUMAR-yz6re
    @NITISHKUMAR-yz6re 6 лет назад +2

    its fun and awesome after watching your consistency

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

    "Have patience, without patience u can never be a good programmer." u nicely said sir,
    Watching this JS series to start the MERN Bootcamp which i bought today. #MERN@199.
    #ThanksForAllYourAmazingVideos

  • @justankit_shrivastava
    @justankit_shrivastava 6 лет назад

    Tha way people run NGOs for social services for the helpless people
    In the same way you run the RUclips channel,we help people
    Really really love u sir 😊👌👌👌👌👌👌

  • @mohitvaishnav7283
    @mohitvaishnav7283 6 лет назад +1

    Dear Sir,
    you should make these programming tutorials on many languages they are very helpful and I am starting to like this already.

  • @EJFF.
    @EJFF. 5 лет назад

    Amazing tutorial Hitesh, thank you for uploading free yet outstanding content.

  • @akshaychauhan917
    @akshaychauhan917 5 лет назад +2

    its not working on cmd using windows.........so use........node fullname_of_the_file_with_path then press enter key...............
    like node E:\foldername\filename then enter

  • @bhanurulz
    @bhanurulz 6 лет назад

    One question related to " const". When we load a page that time const are assigned, generally data will be coming from back-end. So on page load whatever value is set in const will be there till the time till that session time only, if we change anything in back-end, the same will be apply on next page load? So do i assume that const will just hold its initial value only for that particular page load session?

  • @raihanakram530
    @raihanakram530 6 лет назад +2

    4:42
    All humans made mistakes!
    All humans _will continue_ to make mistakes
    We all are humans...(except some I think...)
    #humans

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

    Sir you are really a great teacher.

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

    Thank you so much man!!! Java Script is much easier than c++ I learn so fast with you love ya!

  • @pratapsinghrathour7438
    @pratapsinghrathour7438 6 лет назад +1

    Back to back 4th video.Yeah!!!

  • @ShivamSharma-iq6zb
    @ShivamSharma-iq6zb 6 лет назад

    I am so thankfull to you, for making such videos for us.

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

    i cannot believe you giving this for free

  • @YogeshKumar-bp5dr
    @YogeshKumar-bp5dr 6 лет назад

    Thanks sir. I have been following you from a long time. Your videos helped me a lot. I want to go into web development. I have learned html and css. Now i want to learn JavaScript. You are using node.js here. I am little a bit confused how i can use this in web development? Please help me out in getting started.

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

    Other than skills u do have a good vocal with awesome communications

  • @dharmendraprasad198
    @dharmendraprasad198 6 лет назад

    Thanq for this course sir.....it's will improve my concept of js

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

    Try make it a practice of using semi colon to close statements and you could have use the internal terminal in visual studio code.

  • @YasirKhan-bl8lj
    @YasirKhan-bl8lj 4 года назад

    Thanks Hitesh

  • @ajinkyashinde6345
    @ajinkyashinde6345 6 лет назад

    awesome course sir
    i m loving it

  • @subodhkamble6480
    @subodhkamble6480 6 лет назад

    It's fun to learn with you sir ,thanks ❤️

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

    just one word
    AMAZING !!

  • @ruhankhandaker5198
    @ruhankhandaker5198 6 лет назад

    i think we'll get all all part of this series.. saltue sir

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

    bro you solved my problem thanks

  • @shankarsingh7842
    @shankarsingh7842 6 лет назад +1

    Keep uploading😀😀

  • @sandeepreddy830
    @sandeepreddy830 6 лет назад +1

    Upload more videos from the course sir😊😊

  • @YOYO-dl6fe
    @YOYO-dl6fe 6 лет назад

    Showers of Javascript!!

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

    Hey guys!! there s a faster way to run java scripts using the code runner extension, just search up code runner in vscode extension's tab and install it.

  • @skillfulactor09
    @skillfulactor09 6 лет назад

    I love u man hitesh you are a great inspiration to me are you going to make Vue js. videos

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

    hummmmm
    i learned alot today i am 14 year kid i want to learn i play games so i want to make a game my self

  • @maths_kamlesh1787
    @maths_kamlesh1787 6 лет назад

    Hi Hitesh
    I can also use the variable without let as a keyword. Is it necessary to use let?

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

    what's differences between "var" and "let" when we declare a variable brother?

  • @sriharshajaddu3426
    @sriharshajaddu3426 6 лет назад

    Can you explain phases of web development for learning... Like fist html then css and next js.
    Reply would be helpful!!

  • @curious.ankit.kumar.
    @curious.ankit.kumar. 5 лет назад

    Sir I have encountered a interesting doubt
    const string='java'
    const STRING='script';
    const String=' is Easy..!!'
    console.log(string+STRING+String);
    i got the output: javascript is Easy..!!
    without any error but the VS Code editor show the three variable names String,STRING and string with three different colour...ideally all the variable names should have same colour
    Sir please show some light on the situation what is happening ?

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

    please explain difference between usage of let and var.

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

    I have seen var used to represent a variable in JavaScript. Is there a specific rule of when to use let to represent a variable as opposed to var? Is one method better than the other?

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

    Why are we using let to declare variable where we use var to declare in javascript

  • @gauravk4050
    @gauravk4050 6 лет назад

    great javascript series...

  • @mohitvaishnav7283
    @mohitvaishnav7283 6 лет назад

    please also do some practical use of javascript where we can learn real life applications BTW amazing videos 😍 😍

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

    const name ='priyanth'
    {
    const name = 'Raju'
    console.log(name);
    }
    In the above example am getting o/p raju how it is possible to change const value pls explain

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

    i think their is another method too: console.log(first_name+ '\t '+last_name)

  • @dhananjaychoudhary2110
    @dhananjaychoudhary2110 6 лет назад +2

    Sir are we getting the whole series today😀

    • @HiteshCodeLab
      @HiteshCodeLab  6 лет назад +2

      nahhhh, not that quick because videos need to be polished and need to be in same audio and video quality.

  • @hemantkumar-zh1bo
    @hemantkumar-zh1bo 5 лет назад

    Hi Hitesh, can u please explain difference between var and let keywords

  • @yashrajanshukla7790
    @yashrajanshukla7790 6 лет назад +1

    Hey why youtube is not sending notifications?..

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

    can you explain the diff bw var, const and let and their scopes?

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

    Do we use the( let) keyword to declare variable?

  • @shahidullahmiazi
    @shahidullahmiazi 6 лет назад

    Without let or var keyword my all variable smoothly work! So, why I use both? May I use these only using const keyword?

  • @ajaydshimpi4889
    @ajaydshimpi4889 6 лет назад

    Awesome sir

  • @padmajapatil8996
    @padmajapatil8996 6 лет назад

    Wow its very nice thanku soo much:)

  • @rockybhai-cn3qw
    @rockybhai-cn3qw 5 лет назад

    always present sir

  • @abhinavgupta4816
    @abhinavgupta4816 6 лет назад

    Hi, I am using windows 7 and in my cmd prompt , " node variables.js" is running but not showing the output, could you please help me out with any suggestions.........

  • @govindrathi5632
    @govindrathi5632 6 лет назад

    """""
    let r = 33
    let bonus = 20
    let total = r + bonus
    console.log(total);
    /*
    Exception: SyntaxError: redeclaration of let name
    @Scratchpad/1:1:1
    */
    """""
    now what is this sir?

  • @realRohit001
    @realRohit001 6 лет назад

    So as I learned earlier that "var" is the keyword use to declare a variable. So why is it "let" here?

    • @dotslashtarun
      @dotslashtarun 6 лет назад +2

      there are some subtle differences between their scopes
      var is scoped to the nearest function block and let is scoped to the nearest enclosing block, which can be smaller than a function block. Both are global if outside any block.

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

    what's the difference between a var and let

  • @dhananjaychoudhary2110
    @dhananjaychoudhary2110 6 лет назад

    Great sir

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

    Thank you sir

  • @sandeepkumarmishra7267
    @sandeepkumarmishra7267 6 лет назад

    thankuuu sir....

  • @dhruvdesai391
    @dhruvdesai391 6 лет назад

    hey, I am a IT student and i have learn java Script basics before, we were writing it in and running in browser .
    But what you did is completely different and we have't declared variables like that.and we never used node i am not getting why it is different.

    • @HiteshCodeLab
      @HiteshCodeLab  6 лет назад

      I think you should start from 1st video.

  • @vigneshwaran.palani
    @vigneshwaran.palani 5 лет назад

    let or var ? both of them are different? or same ?

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

    Name =20; also works y?? Even if its not declared

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

    Can we have var as variable instead of let ?

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

    What is difference in using let and var in JS... can't find it

  • @visheshpandita2787
    @visheshpandita2787 6 лет назад

    whats difference between var and let?

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

    Can i use the terminal in vs code to produce the output?

  • @padmajapatil8996
    @padmajapatil8996 6 лет назад

    Sir we r using var insted of let than whats differnce in that?

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

    var and let are the same and totalscore is not printing in browser.

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

    how to use javascript with html for example created a button using html and want to work this button then how it posible

  • @RahulSharma-ot6hl
    @RahulSharma-ot6hl 6 лет назад

    What would happen if u add name and bonus.??

  • @abhichauhan8811
    @abhichauhan8811 6 лет назад

    after running the program in command prompt the output is not showing please help sir

  • @vishalb9599
    @vishalb9599 6 лет назад

    can't we run those codes in that GUI environment/ide bcoz I don't like to use the command prompt or terminal

  • @nishantprajapati7166
    @nishantprajapati7166 6 лет назад

    what is difference between "let" and "var".

  • @SoyEdrey_
    @SoyEdrey_ 2 года назад

    why dont you use Var instead of let. i ask because im learning based on Var. im just asking :)

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

    please tell how to download the sublime text that u are using............provide link for every things.................

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

    why dont u use var name=‘john’; please explain .

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

    Sir which theme are u using in Vs?

  • @yashshende2786
    @yashshende2786 6 лет назад +2

    RUclips is gonna be mad it not even sending me a notification
    #dumb_RUclips

  • @subhoneeldatta6011
    @subhoneeldatta6011 6 лет назад

    let firstName = 'John'
    let lastName = 'Doe'
    console.log(firstName + ' ' + lastName)
    it print the single name what if we print multiple name?

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

    My Command Prompt Doesn't work :( Can you help?

  • @XXXXAman
    @XXXXAman 6 лет назад

    hi hitesh ,
    whats the difference between 'aman' and "aman" , using single quote and double quote ?

    • @izaanjahangir834
      @izaanjahangir834 6 лет назад +1

      Aman Shrivastava there is no difference in there it's just depends on preference to use single or double quotes

    • @XXXXAman
      @XXXXAman 6 лет назад

      izaan jahangir thanks

  • @bhuwanadhikari6732
    @bhuwanadhikari6732 6 лет назад

    make a video about progressive web app and it's future

  • @chaitanyakumarreddy1776
    @chaitanyakumarreddy1776 6 лет назад

    What is node.js???please explain me in detail sir

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

    I am writing the code in Visual Study. Can anyone please help me that is how to run the code. I have typed but is not able to run it. Please help me

  • @gtxfalcon003
    @gtxfalcon003 2 года назад

    hello sir, while using let name = "John" and console.log(name), the error of name is @depreciated is coming, even after using var. how do i solve this error? pls help sir and other fellow users...

  • @bhanurulz
    @bhanurulz 6 лет назад

    Hello Sir, if I am adding 100.0 and 20 , why the result is not coming in decimal number?

    • @thotashiridi5964
      @thotashiridi5964 6 лет назад

      The result of addition is "120.0", which is nothing but "120". may be that is why it not showing up decimal or float numbers. Please try to add with 100.05 or give any integer after 100.0, that should give you decimal value in the addition result.

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

    when i write let is showing error in dreamwever

  • @tabishmanzoor4154
    @tabishmanzoor4154 6 лет назад

    good video :)

  • @shubhamsharma-pu2sp
    @shubhamsharma-pu2sp 6 лет назад

    Hey sir, We can call variable by 'VAR'

    • @HiteshCodeLab
      @HiteshCodeLab  6 лет назад

      Yep, but let and const are more of a standard now.

    • @shubhamsharma-pu2sp
      @shubhamsharma-pu2sp 6 лет назад

      How can I setup my atom for different languages I don't know how to do it..

  • @Harendrasingh-op3lv
    @Harendrasingh-op3lv 6 лет назад

    how to update the node -v in ubuntu...
    while runing variable.js
    following msg appear in my terminal--/home/harendra/hiteshSir/variable.js:1
    (function (exports, require, module, __filename, __dirname) { let name = 'john';
    ^^^
    SyntaxError: Block-scoped declarations (let, const, function, class) not yet supported outside strict mode
    at exports.runInThisContext (vm.js:53:16)
    at Module._compile (module.js:374:25)
    at Object.Module._extensions..js (module.js:417:10)
    at Module.load (module.js:344:32)
    at Function.Module._load (module.js:301:12)
    at Function.Module.runMain (module.js:442:10)
    at startup (node.js:136:18)
    at node.js:966:3

  • @pranavkushwaha6016
    @pranavkushwaha6016 6 лет назад

    present sir

  • @kundanpandey5442
    @kundanpandey5442 6 лет назад

    Nice :)

  • @priyamvashi2187
    @priyamvashi2187 6 лет назад

    great :)