---
title: "Discussion on \"JS Expression, Statement;\" | Hashnode"
description: "Discussion on \"JS Expression, Statement;\". Two major syntax catogories in JS\n\nStatement\nExpression\n\nWe have expression statement but not statement expression because expression can sometime act as statements thus expression statement\nExpression\nExpression are js code snippets that results in ..."
url: "https://hashnode.com/posts/js-expression-statement/5f83f2df365d8e30601320fc"
---

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

Discussion

# [JS Expression, Statement;](https://rohitgeddam.hashnode.dev/js-expression-statement?utm_source=hashnode&utm_medium=feed)

Two major syntax catogories in JS Statement Expression We have expression statement but not statement expression because expression can sometime act as statements thus expression statement Expression Expression are js code snippets that results in ...

Oct 12, 2020 · 2 min read · rohitgeddam.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)

## Written by

[rohit geddam](https://hashnode.com/@rohitgeddam)

@rohitgeddam

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

solving problems 1 bit at a time.

## Responses 1

Markdown supported · ⌘↵ to post

[Alex Sunny](https://hashnode.com/@alexsunny123)

[Oct 15, 2020](https://hashnode.com/posts/js-expression-statement/5f83f2df365d8e30601320fc/comment/5f884b36d7dc0b17a97a1134)

Hello,

You can try it hope this will work.

function changeThatArray(arr) { arr\[0\] = 100; }

var sampleArray = \[10,20,30\]

console.log(sampleArray\[0\]); // 10

changeThatArray(sampleArray); [ometv.onl](https://ometv.onl/) [chatroulette.top](https://chatroulette.top/) [omegle.wtf](https://omegle.wtf/) [bazoocam.cam](https://bazoocam.cam/) console.log(sampleArray\[0\]); // 100

thanks alexsunny
