From b77f21494b130d1614ed8ffca3268c3ba9fb2272 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C2=A1ke?= <77801554+front42@users.noreply.github.com> Date: Fri, 12 Dec 2025 17:11:59 +0300 Subject: [PATCH] fix: correct function expression in var article.md en --- 1-js/06-advanced-functions/04-var/article.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/1-js/06-advanced-functions/04-var/article.md b/1-js/06-advanced-functions/04-var/article.md index 28d7a76ec8..7b9212e9f6 100644 --- a/1-js/06-advanced-functions/04-var/article.md +++ b/1-js/06-advanced-functions/04-var/article.md @@ -227,7 +227,7 @@ An IIFE looks like this: Here, a Function Expression is created and immediately called. So the code executes right away and has its own private variables. -The Function Expression is wrapped with parenthesis `(function {...})`, because when JavaScript engine encounters `"function"` in the main code, it understands it as the start of a Function Declaration. But a Function Declaration must have a name, so this kind of code will give an error: +The Function Expression is wrapped with parenthesis `(function() {...})`, because when JavaScript engine encounters `"function"` in the main code, it understands it as the start of a Function Declaration. But a Function Declaration must have a name, so this kind of code will give an error: ```js run // Tries to declare and immediately call a function