--- id: 56533eb9ac21ba0edf2244b7 title: Concatenating Strings with Plus Operator challengeType: 1 videoUrl: '' localeTitle: سلاسل متسلسلة مع Plus Operator --- ## Description
في JavaScript ، عندما يتم استخدام عامل التشغيل + مع قيمة String ، يطلق عليه عامل التشغيل السلسة . يمكنك إنشاء سلسلة جديدة خارج السلاسل الأخرى عن طريق وصلها معًا. مثال
"اسمي ألان ،" + "أنا سلسلته".
ملحوظة
احترس من المساحات. لا يضيف Concatenation فراغات بين السلاسل المتسلسلة ، لذا ستحتاج إلى إضافتها بنفسك.
## Instructions
بناء myStr من السلاسل "This is the start. " و "This is the end." باستخدام عامل + .
## Tests
```yml tests: - text: يجب أن يكون لـ myStr قيمة This is the start. This is the end. testString: 'assert(myStr === "This is the start. This is the end.", "myStr should have a value of This is the start. This is the end.");' - text: استخدم عامل التشغيل + لبناء myStr testString: 'assert(code.match(/([""]).*([""])\s*\+\s*([""]).*([""])/g).length > 1, "Use the + operator to build myStr");' - text: يجب إنشاء myStr باستخدام الكلمة الرئيسية var . testString: 'assert(/var\s+myStr/.test(code), "myStr should be created using the var keyword.");' - text: تأكد من تعيين النتيجة لمتغير myStr . testString: 'assert(/myStr\s*=/.test(code), "Make sure to assign the result to the myStr variable.");' ```
## Challenge Seed
```js // Example var ourStr = "I come first. " + "I come second."; // Only change code below this line var myStr; ```
### After Test
```js console.info('after the test'); ```
## Solution
```js // solution required ```