--- id: 56533eb9ac21ba0edf2244a9 title: تهيئة المتغيرات باستخدام مشغل التعيين (Initializing Variables with the Assignment Operator) challengeType: 1 videoUrl: 'https://scrimba.com/c/cWJ4Bfb' forumTopicId: 301171 dashedName: initializing-variables-with-the-assignment-operator --- # --description-- من الشائع تعيين للمتغير قيمة أولية في نفس السطر المعلن عنه. ```js var myVar = 0; ``` ينشئ متغيرًا جديدًا يسمى `myVar` ويعينه قيمة مبدئية تبلغ `0`. # --instructions-- عرّف متغير `a` باستخدام `var` و عيّن له قيمة `9`. # --hints-- يجب عليك تهيئة `a` بقيمة `9`. ```js assert(/var\s+a\s*=\s*9(\s*;?\s*)$/.test(code)); ``` # --seed-- ## --seed-contents-- ```js ``` # --solutions-- ```js var a = 9; ```