fix: converted single to triple backticks9 (#36236)
This commit is contained in:
@@ -6,11 +6,12 @@ localeTitle: حائط اللوب
|
||||
|
||||
في `while` حلقة تنفيذ مرارا وتكرارا على كتلة من البيانات حتى الشرط المحدد داخل الأقواس بتقييم ل `false` . على سبيل المثال:
|
||||
|
||||
`while (some_condition_is_true)
|
||||
{
|
||||
// do something
|
||||
}
|
||||
`
|
||||
```java
|
||||
while (some_condition_is_true)
|
||||
{
|
||||
// do something
|
||||
}
|
||||
```
|
||||
|
||||
يتم تنفيذ كل "التكرار" (من تنفيذ كتلة البيانات) من قبل تقييم الشرط المحدد داخل الأقواس - يتم تنفيذ البيانات فقط إذا تم تقييم الشرط إلى `true` . إذا تم تقييمه إلى " `false` ، يتم استئناف تنفيذ البرنامج من العبارة الموجودة مباشرةً بعد المربع " `while` .
|
||||
|
||||
@@ -20,21 +21,23 @@ localeTitle: حائط اللوب
|
||||
|
||||
في المثال التالي ، يتم إعطاء `expression` بواسطة `iter_While < 10` . نحن زيادة `iter_While` بواسطة `1` كل مرة يتم تنفيذ الحلقة. حلقة `while` فواصل عندما تصل قيمة `iter_While` إلى `10` .
|
||||
|
||||
`int iter_While = 0;
|
||||
while (iter_While < 10)
|
||||
{
|
||||
System.out.print(iter_While + " ");
|
||||
// Increment the counter
|
||||
// Iterated 10 times, iter_While 0,1,2...9
|
||||
iter_While++;
|
||||
}
|
||||
System.out.println("iter_While Value: " + iter_While);
|
||||
`
|
||||
```java
|
||||
int iter_While = 0;
|
||||
while (iter_While < 10)
|
||||
{
|
||||
System.out.print(iter_While + " ");
|
||||
// Increment the counter
|
||||
// Iterated 10 times, iter_While 0,1,2...9
|
||||
iter_While++;
|
||||
}
|
||||
System.out.println("iter_While Value: " + iter_While);
|
||||
```
|
||||
|
||||
انتاج:
|
||||
|
||||
`0 1 2 3 4 5 6 7 8 9
|
||||
iter_While Value: 10
|
||||
`
|
||||
```
|
||||
0 1 2 3 4 5 6 7 8 9
|
||||
iter_While Value: 10
|
||||
```
|
||||
|
||||
 [تشغيل الكود](https://repl.it/CJYj/0)
|
Reference in New Issue
Block a user