main.ts

Fri, 19 Sep 2025 11:49:40 +0800

author
Gong Zhile <gongzl@stu.hebust.edu.cn>
date
Fri, 19 Sep 2025 11:49:40 +0800
changeset 0
a3bb50016d6f
permissions
-rw-r--r--

Initial Commit

0
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
1 export function add(a: number, b: number): number {
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
2 return a + b;
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
3 }
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
4
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
5 // Learn more at https://docs.deno.com/runtime/manual/examples/module_metadata#concepts
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
6 if (import.meta.main) {
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
7 console.log("Add 2 + 3 =", add(2, 3));
a3bb50016d6f Initial Commit
Gong Zhile <gongzl@stu.hebust.edu.cn>
parents:
diff changeset
8 }

mercurial