Lesson 6 of 34
if మరియు else: నిర్ణయాలు తీసుకోవడం
8 min 25 XP
Condition true అయినప్పుడే if కోడ్ను నడుపుతుంది; లేకపోతే else భాగం నడుస్తుంది. Condition ను ( ) brackets లోపల రాస్తాం.
Example: edit me and press Run
Output Loading Java (first time takes a few seconds)
Press Run to see the result here.Comparison operators: == సమానం, != సమానం కాదు, > ఎక్కువ, < తక్కువ, >= ఎక్కువ లేదా సమానం, <= తక్కువ లేదా సమానం. ప్రతిదీ boolean (true/false) ఇస్తుంది.
Example: edit me and press Run
Output Loading Java (first time takes a few seconds)
Press Run to see the result here.= value ను నిల్వ చేస్తుంది, == పోలుస్తుంది. వీటిని కలపడం అత్యంత సాధారణ తప్పులలో ఒకటి.