Thida Lang
  • Getting Start
    • Introduction
    • Usage
  • Documentation
    • Expression
    • Print Output
    • Data Types
    • Variables
    • Operators
    • Control flow
    • Function
  • Contribution
    • Contributor
    • Acknowledgement
  • References
    • Myanmar grammar
    • Python
Powered by GitBook
On this page
  1. Documentation

Control flow

Control Flow

If Else

To use conditional statements:

 သည်  ဖြစ်လျှင် () ကို အဖြေထုတ်ပါ။ မဖြစ်ပါက (  ) ကို အဖြေထုတ်ပါ။

Example:

 ( a > b ) သည် ( "a is greater" ) ဖြစ်လျှင် ( "a is greater" ) ကို အဖြေထုတ်ပါ။ မဖြစ်ပါက ( "b is greater" ) ကို အဖြေထုတ်ပါ။

For Loop

To use a for loop:

( variable = start_value ; variable < end_value ; variable = variable + increment ) ( loop_body ) ကို လုပ်ဆောင်ပါ။

Example:

( i = 0 ; i < 10 ; i = i + 1 ) ( "Loop iteration " , i ) ကို လုပ်ဆောင်ပါ။

While Loop

To use a while loop:

( condition ) ဖြစ်နေသမျှ ( loop_body ) ကို လုပ်ဆောင်ပါ။

Example:

 ( a < 10 ) ဖြစ်နေသမျှ ( a ကို အဖြေထုတ်ပါ။ a = a + 1 ) ကို လုပ်ဆောင်ပါ။
PreviousOperatorsNextFunction

Last updated 1 year ago