Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import 'dart:io';
- String say(String from, String message, {String to, String appName}) {
- return from + " say " + message + ((to != null) ? " to " + to : " ") + ((appName != null) ? " via " + appName : " ");
- }
- String say2(String from, String message, [String to, String appName]) {
- return from + " say " + message + ((to != null) ? " to " + to : " ") + ((appName != null) ? " via " + appName : " ");
- }
- double luas_segiempat(double panjang, double lebar) => panjang * lebar;
- main(List<String> arguments) {
- Function f;
- f = luas_segiempat;
- print(say("Johny", "Hello", to: "Mada", appName: "WA"));
- print(say2("Johny", "Hello", "Mada", "WA"));
- print(f(6.0, 3.0));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement