---
title: "Discussion on \"Different ways to declare variables in JavaScript\" | Hashnode"
description: "Discussion on \"Different ways to declare variables in JavaScript\". In any programming language, variables are named containers containing any type of data at a specific memory location. The name of every variable must be unique.\nIn JavaScript, we can create a variable in 3 ways :\n\nusing var -\n\nvar name; // only decl..."
url: "https://hashnode.com/posts/different-ways-to-declare-variables-in-javascript/63e874121b910905e531b70d"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [Different ways to declare variables in JavaScript](https://shrianshblogs.hashnode.dev/different-ways-to-declare-variables-in-javascript?utm_source=hashnode&utm_medium=feed)

In any programming language, variables are named containers containing any type of data at a specific memory location. The name of every variable must be unique. In JavaScript, we can create a variable in 3 ways : using var - var name; // only decl...

Feb 12, 2023 · 2 min read · shrianshblogs.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#variables](https://hashnode.com/tag/variables)
-   [#var-let-const](https://hashnode.com/tag/var-let-const)

## Written by

[Shriansh Kumar](https://hashnode.com/@shrianshkr)

@shrianshkr · Hyderabad, Telangana, India

  
[View profile](https://hashnode.com/@shrianshkr)

MCA Student

## Responses 1

Markdown supported · ⌘↵ to post

[Mona Singh](https://hashnode.com/@monasingh14)

[Feb 12, 2023](https://hashnode.com/posts/different-ways-to-declare-variables-in-javascript/63e874121b910905e531b70d/comment/63e88c19861f30240f6df110)

Informative and understandable 🙌
