Calling a Function

Let’s study function invocation in Dart.

A simple function call

When you want to use a function, it needs to be invoked by being called upon. You call a user-defined function the same way you call a built-in function; by calling its name followed by the input in (). Let’s call the newPrint function and sum function we defined in the previous lesson.

We will be storing the return value of any function with a return value in a variable result.

Create a free account to access the full course.

Continue your learning journey with a 14-day free trial.

By signing up, you agree to Educative's Terms of Service and Privacy Policy