Dart : Programming language

Aditi Dosi
2 min readSep 9, 2022

--

Dart is a programming language designed for client development, such as for the web and mobile apps. It is developed by Google and can also be used to build server and desktop applications. It is an object-oriented, class-based, garbage-collected language with C-style syntax.

Dart is an open source, purely object-oriented, optionally typed, and a class-based language which has excellent support for functional as well as reactive programming. Unlike C# or Java, Dart is not bloated at all. In fact, it’s a relatively simple, modern and highly efficient language to work with.

In the Stack Overflow ranking of the most popular technologies in 2021, Dart is in 7th place behind Julia. This is not so surprising. The Dart-based UI toolkit Flutter for platform-agnostic development of user interfaces had a notable contributor increase in 2021.

Does Dart have a future?

A future is a valuable construct that allows asynchronous programming in Dart. Asynchronous programming is programming that caters to delayed operations. These delayed operations happen when you need to fetch data over a server, write to a database, or read a file on the system (commonly referred to as I/O operations).

Is Dart front end or backend?

Dart is currently actively used with Flutter for developing the frontend of cross-platform mobile apps. Dart can be also used for web development, but there is no mention of Dart being used for backend development.

Google engineers use Dart to create many apps, including some that are essential to Google’s business. For example, if you use the Google Ads web or mobile app, you’re using a Dart app that supports much of Google’s revenue.

Dart is one of very few languages (and perhaps the only “mainstream” language) that is well suited to being compiled both AOT and JIT. Supporting both kinds of compilation provides significant advantages to Dart and (especially) Flutter.

Example

In this example, we will try to conditionally execute a block of statements based on a boolean expression.

main.dart

void main(){

int a = 10;

if(a%2==0){

print('$a is even number.');

}

if(a%2==1){

print('$a is odd number.');

}

}

Output

10 is even number.

--

--