Logo

dev-resources.site

for different kinds of informations.

Control Flow Statements ( if, else, else if) in dart (Bangla)

Published at
12/31/2024
Categories
dart
flutter
programming
bangla
Author
amirul897
Categories
4 categories in total
dart
open
flutter
open
programming
open
bangla
open
Author
9 person written this
amirul897
open
Control Flow Statements ( if, else, else if) in dart (Bangla)

Dart āĻĒā§āĻ°ā§‹āĻ—ā§āĻ°āĻžāĻŽāĻŋāĻ‚ āĻ­āĻžāĻˇāĻžāĻ¯āĻŧ Control Flow Statements (āĻ¯ā§‡āĻŽāĻ¨: if, else, else if) āĻŦā§āĻ¯āĻŦāĻšāĻžāĻ° āĻ•āĻ°āĻž āĻšāĻ¯āĻŧ āĻ•ā§‹āĻ¨ā§‹ āĻ¨āĻŋāĻ°ā§āĻĻāĻŋāĻˇā§āĻŸ āĻļāĻ°ā§āĻ¤ āĻ…āĻ¨ā§āĻ¯āĻžāĻ¯āĻŧā§€ āĻ•ā§‹āĻĄā§‡āĻ° 흐āĻžā§Ž āĻĒāĻ°āĻŋāĻŦāĻ°ā§āĻ¤āĻ¨ āĻ•āĻ°āĻžāĻ° āĻœāĻ¨ā§āĻ¯āĨ¤ āĻāĻ—ā§āĻ˛āĻŋ āĻŦāĻŋāĻ­āĻŋāĻ¨ā§āĻ¨ āĻļāĻ°ā§āĻ¤ā§‡āĻ° āĻ­āĻŋāĻ¤ā§āĻ¤āĻŋāĻ¤ā§‡ āĻ•ā§‹āĻĄā§‡āĻ° āĻĒā§āĻ°āĻŦāĻžāĻš āĻ¨āĻŋāĻ¯āĻŧāĻ¨ā§āĻ¤ā§āĻ°āĻŖ āĻ•āĻ°ā§‡āĨ¤

ā§§. if Statement

if statement āĻļāĻ°ā§āĻ¤ā§‡āĻ° āĻ­āĻŋāĻ¤ā§āĻ¤āĻŋāĻ¤ā§‡ āĻāĻ•āĻŸāĻŋ āĻ•ā§‹āĻĄ āĻŦā§āĻ˛āĻ• āĻšāĻžāĻ˛āĻžāĻ¨ā§‹āĻ° āĻœāĻ¨ā§āĻ¯ āĻŦā§āĻ¯āĻŦāĻšā§ƒāĻ¤ āĻšāĻ¯āĻŧāĨ¤ āĻ¯āĻĻāĻŋ āĻļāĻ°ā§āĻ¤āĻŸāĻŋ true āĻšāĻ¯āĻŧ, āĻ¤āĻžāĻšāĻ˛ā§‡ āĻ•ā§‹āĻĄ āĻŦā§āĻ˛āĻ•āĻŸāĻŋ āĻšāĻ˛āĻŦā§‡āĨ¤

Syntax:

if (condition) {
  // code to be executed if condition is true
}
Enter fullscreen mode Exit fullscreen mode

Example:

int num = 10;

if (num > 5) {
  print('The number is greater than 5');
}
Enter fullscreen mode Exit fullscreen mode

āĻāĻ–āĻžāĻ¨ā§‡, num > 5 āĻļāĻ°ā§āĻ¤āĻŸāĻŋ true āĻšāĻ“āĻ¯āĻŧāĻžāĻ¯āĻŧ print āĻ¸ā§āĻŸā§‡āĻŸāĻŽā§‡āĻ¨ā§āĻŸāĻŸāĻŋ āĻšāĻžāĻ˛ā§ āĻšāĻŦā§‡āĨ¤

ā§¨. else Statement

else statement āĻ¤āĻ–āĻ¨ āĻŦā§āĻ¯āĻŦāĻšā§ƒāĻ¤ āĻšāĻ¯āĻŧ āĻ¯āĻ–āĻ¨ if āĻļāĻ°ā§āĻ¤āĻŸāĻŋ false āĻšāĻ¯āĻŧāĨ¤ āĻ…āĻ°ā§āĻĨāĻžā§Ž, āĻ¯āĻĻāĻŋ if āĻļāĻ°ā§āĻ¤āĻŸāĻŋ āĻĒā§‚āĻ°ā§āĻŖ āĻ¨āĻž āĻšāĻ¯āĻŧ, āĻ¤āĻžāĻšāĻ˛ā§‡ else āĻŦā§āĻ˛āĻ•āĻŸāĻŋ āĻšāĻ˛āĻŦā§‡āĨ¤

Syntax:

if (condition) {
  // code to be executed if condition is true
} else {
  // code to be executed if condition is false
}
Enter fullscreen mode Exit fullscreen mode

Example:

int num = 3;

if (num > 5) {
  print('The number is greater than 5');
} else {
  print('The number is not greater than 5');
}
Enter fullscreen mode Exit fullscreen mode

āĻāĻ–āĻžāĻ¨ā§‡, num > 5 āĻļāĻ°ā§āĻ¤āĻŸāĻŋ false āĻšāĻ“āĻ¯āĻŧāĻžāĻ¯āĻŧ else āĻŦā§āĻ˛āĻ•āĻŸāĻŋ āĻ•āĻžāĻ°ā§āĻ¯āĻ•āĻ° āĻšāĻŦā§‡ āĻāĻŦāĻ‚ "The number is not greater than 5" āĻĒā§āĻ°āĻŋāĻ¨ā§āĻŸ āĻšāĻŦā§‡āĨ¤

ā§Š. else if Statement

āĻ¯āĻ–āĻ¨ āĻāĻ•āĻžāĻ§āĻŋāĻ• āĻļāĻ°ā§āĻ¤ āĻšā§‡āĻ• āĻ•āĻ°āĻ¤ā§‡ āĻšāĻ¯āĻŧ, āĻ¤āĻ–āĻ¨ else if āĻŦā§āĻ¯āĻŦāĻšāĻžāĻ° āĻ•āĻ°āĻž āĻšāĻ¯āĻŧāĨ¤ āĻāĻ•āĻžāĻ§āĻŋāĻ• āĻļāĻ°ā§āĻ¤ āĻĒāĻ°ā§€āĻ•ā§āĻˇāĻž āĻ•āĻ°āĻ¤ā§‡, āĻĒā§āĻ°āĻĨāĻŽā§‡ if āĻŦā§āĻ˛āĻ•āĻŸāĻŋ āĻšā§‡āĻ• āĻšāĻ¯āĻŧ, āĻ¤āĻžāĻ°āĻĒāĻ° else if āĻļāĻ°ā§āĻ¤āĻ—ā§āĻ˛ā§‹ āĻšā§‡āĻ• āĻ•āĻ°āĻž āĻšāĻ¯āĻŧ, āĻāĻŦāĻ‚ āĻ…āĻŦāĻļā§‡āĻˇā§‡ else āĻŦā§āĻ˛āĻ•āĻŸāĻŋ āĻšāĻžāĻ˛āĻžāĻ¨ā§‹ āĻšāĻ¯āĻŧ āĻ¯āĻĻāĻŋ āĻ•ā§‹āĻ¨ āĻļāĻ°ā§āĻ¤āĻ‡ āĻ¸āĻ āĻŋāĻ• āĻ¨āĻž āĻšāĻ¯āĻŧāĨ¤

Syntax:

if (condition1) {
  // code to be executed if condition1 is true
} else if (condition2) {
  // code to be executed if condition2 is true
} else {
  // code to be executed if none of the conditions are true
}
Enter fullscreen mode Exit fullscreen mode

Example:

int num = 7;

if (num > 10) {
  print('The number is greater than 10');
} else if (num == 7) {
  print('The number is 7');
} else {
  print('The number is less than 10');
}
Enter fullscreen mode Exit fullscreen mode

āĻāĻ–āĻžāĻ¨ā§‡, num == 7 āĻļāĻ°ā§āĻ¤āĻŸāĻŋ true āĻšāĻ“āĻ¯āĻŧāĻžāĻ¯āĻŧ "The number is 7" āĻĒā§āĻ°āĻŋāĻ¨ā§āĻŸ āĻšāĻŦā§‡āĨ¤

āĻ¸āĻ‚āĻ•ā§āĻˇā§‡āĻĒā§‡:

  • if statement: āĻļāĻ°ā§āĻ¤ āĻĒā§‚āĻ°ā§āĻŖ āĻšāĻ˛ā§‡ āĻ•ā§‹āĻĄ āĻŦā§āĻ˛āĻ• āĻšāĻ˛ā§‡āĨ¤
  • else statement: if āĻļāĻ°ā§āĻ¤ āĻĒā§‚āĻ°ā§āĻŖ āĻ¨āĻž āĻšāĻ˛ā§‡ āĻāĻŸāĻŋ āĻšāĻ˛ā§‡āĨ¤
  • else if statement: āĻāĻ•āĻžāĻ§āĻŋāĻ• āĻļāĻ°ā§āĻ¤ āĻĒāĻ°ā§€āĻ•ā§āĻˇāĻž āĻ•āĻ°ā§‡, āĻĒā§āĻ°āĻĨāĻŽ āĻļāĻ°ā§āĻ¤ āĻĒā§‚āĻ°ā§āĻŖ āĻšāĻ˛ā§‡ āĻ¸ā§‡ āĻ•ā§‹āĻĄ āĻŦā§āĻ˛āĻ• āĻšāĻ˛ā§‡, āĻ…āĻ¨ā§āĻ¯āĻĨāĻžāĻ¯āĻŧ āĻĒāĻ°āĻŦāĻ°ā§āĻ¤ā§€ āĻļāĻ°ā§āĻ¤ āĻšā§‡āĻ• āĻ•āĻ°āĻž āĻšāĻ¯āĻŧāĨ¤
dart Article's
30 articles in total
Favicon
Flutter vs React Native in 2025: A Comprehensive Comparison
Favicon
Deploying Flutter Web Apps using Globe.dev
Favicon
Journey to Clean Architecture: Wrestling with a 10k Line Flutter Legacy Codebase
Favicon
5 Essential Flutter Widgets Every Developer Should Master
Favicon
Mastering Nested Navigation in Flutter with `go_router` and a Bottom Nav Bar
Favicon
Flutter for Beginners: From Installation to Your First App
Favicon
Building a Beautiful Login Screen in Flutter: A Complete Guide
Favicon
Flutter Design Pattern Bussines Logic Component (BLOC)
Favicon
Create Different Type of Flavor on Flutter Application
Favicon
Handling PathAccessException in iOS for File Download
Favicon
Common mistakes in Flutter article series
Favicon
Design Pattern in Flutter MVVM
Favicon
7 Ways to Refactor Your Flutter Application
Favicon
WebRTC vs Agora Video SDK vs ZegoCloud for Video Calling in Flutter: A Comprehensive Comparison
Favicon
From Chaos to Control: The Day I Learned the Magic of Debouncing in Flutter 🚀
Favicon
Syntax of comments in dart
Favicon
My first Dart program
Favicon
Integrate the Gemini REST API in Flutter: Unlock Powerful Generative Language Models for Your Next App
Favicon
Dart Operators Explained in Bangla
Favicon
Control Flow Statements (switch and case) in Dart (Bangla)
Favicon
break, continue in Dart programming (Bangla)
Favicon
Control Flow Statements ( for, while, do-while ) in dart (Bangla)
Favicon
Control Flow Statements ( if, else, else if) in dart (Bangla)
Favicon
Type inference in Dart programming (Bangla)
Favicon
var, final, const in dart programming
Favicon
We are in Top 5 Flutter Of The Year Apps List
Favicon
Class in dart
Favicon
Function in dart
Favicon
Map in Dart
Favicon
List in Dart

Featured ones: