languages
所属分类:collect
开发工具:Dart
文件大小:0KB
下载次数:0
上传日期:2023-10-11 14:18:28
上 传 者:
sh-1993
说明: 学习基本编程语言
(Learning Basic Programming Languages)
文件列表:
.idea/ (0, 2023-10-11)
.idea/basic_languages.iml (563, 2023-10-11)
.idea/modules.xml (282, 2023-10-11)
.idea/vcs.xml (167, 2023-10-11)
dart/ (0, 2023-10-11)
dart/0.hello.dart (41, 2023-10-11)
dart/0.operator.dart (337, 2023-10-11)
dart/1.type/ (0, 2023-10-11)
dart/1.type/1.basic.type.dart (576, 2023-10-11)
dart/1.type/1.complex.type.dart (664, 2023-10-11)
dart/1.type/1.declare.const.dart (1246, 2023-10-11)
dart/1.type/1.declare.variable.dart (805, 2023-10-11)
dart/2.control_flow/ (0, 2023-10-11)
dart/2.control_flow/2.if.dart (408, 2023-10-11)
dart/2.control_flow/2.switch.case.dart (505, 2023-10-11)
dart/3.loop/ (0, 2023-10-11)
dart/3.loop/3.for.dart (975, 2023-10-11)
dart/3.loop/3.while.dart (804, 2023-10-11)
dart/4.function/ (0, 2023-10-11)
dart/4.function/4.1.traditional.function.dart (541, 2023-10-11)
dart/4.function/4.2.defaultValue.function.dart (444, 2023-10-11)
dart/4.function/4.3.optionalArgument.function.dart (409, 2023-10-11)
dart/4.function/4.4.arrow.lambda.function.dart (499, 2023-10-11)
dart/5.class/ (0, 2023-10-11)
dart/5.class/5.List/ (0, 2023-10-11)
dart/5.class/5.List/5.list.dart (1648, 2023-10-11)
dart/5.class/5.Map/ (0, 2023-10-11)
dart/5.class/5.Map/5.map.dart (995, 2023-10-11)
dart/5.class/5.Set/ (0, 2023-10-11)
dart/5.class/5.Set/5.set.dart (342, 2023-10-11)
dart/5.class/5.abstract.extend.dart (3065, 2023-10-11)
dart/5.class/5.concrete.class.dart (980, 2023-10-11)
dart/6.exception/ (0, 2023-10-11)
dart/6.exception/6.exception.dart (413, 2023-10-11)
dart/testunit/ (0, 2023-10-11)
dart/testunit/.metadata (1668, 2023-10-11)
... ...
## A. Basic Dart
### 1. Cài t Dart trên Ubuntu
- Tham kho: [Cài t Dart](https://dart.dev/get-dart)
- Follow chính xác các bc sau y, **khng b 1 lnh nào**:
```
81: $ sudo apt-get update
81: $ sudo apt-get install apt-transport-https
81: $ wget -qO- https://dl-ssl.google.com/linux/linux_signing_key.pub | sudo gpg --dearmor -o /usr/share/keyrings/dart.gpg
81: $ echo 'deb [signed-by=/usr/share/keyrings/dart.gpg arch=amd64] https://storage.googleapis.com/download.dartlang.org/linux/debian stable main' | sudo tee /etc/apt/sources.list.d/dart_stable.list
```
```
81: $ sudo apt-get update
81: $ sudo apt-get install dart
```
```
81: $ export PATH="$PATH:/usr/lib/dart/bin"
```
- Thay i PATH cho future terminal sessions
```
81: $ echo 'export PATH="$PATH:/usr/lib/dart/bin"' >> ~/.profile
```
### 2. Vit code vi Dart
- **Khi vit code, cu lnh phi kt thúc bng du chm phy (;)**
- Tham kho: [Dart basic syntax](https://www.raywenderlich.com/books/dart-apprentice/v1.0/chapters/1-hello-dart)
### 3. Biên dch và chy file dart
- M termial và chy cu lnh
```
81: $ dart run
```
- Ví d:
```
81: $ dart run hello.dart
--> Hello, Dart!
```
### 4. Note
- **T khóa var: Ch c gán bin cho giá tr cùng kiu**
- **T khóa dynamic: Gán thoi mái**
- [Label to break loop more accurately](https://www.tutorialspoint.com/dart_programming/dart_programming_loops.htm)
- [Final và const trong dart](https://linhta.dev/blog/final-va-const-trong-dart/#update)
- **mixin** khác class thng thng ch:
- mixin khng có constructor nên khng th to i tng.
- mixin ch có th s dng implements hoc with ch khng th extends
- mixin có th gii hn nhng class nào c phép s dng code ca mình bng t khóa mixin on
- **import 'dart:collection';** to use **HashMap, HashSet, LinkedList ...**
## A1. Objective-C
### Set up instruction & Syntax
- [**Introduction & Syntax URL of Obj-C**](https://www.tutorialspoint.com/objective_c/index.htm)
## A2. Swift
### Set up instruction & Syntax
- [**Introduction & Syntax URL of Swift**](https://www.tutorialspoint.com/swift/index.htm)
## A3. Kotlin
### Set up instruction & Syntax
- [**Introduction & Syntax URL of Kotlin**](https://www.tutorialspoint.com/kotlin/index.htm)
- [**Install & execute instruction**](https://kotlinlang.org/docs/command-line.html#snap-package)
1. Using snap with Ubuntu version >= 16.0
```
sudo snap install --classic kotlin
```
2. Compile with command line
```
../kotlin$ kotlinc .kt -include-runtime -d .jar
```
3. Using java complier to execute the results from **.jar** file
```
../kotlin$ java -jar .jar
```
## B. Basic TypeScript from beginning
#### Install TypeScript
```npm install -g typescript```
#### Check version of TypeScript
```tsc -v```
#### Compile & Run
```tsc .ts && node .js```
#### nodemon
* Khi code thay i, h thng t cp nht li code và build li ngay cho dev, khng cn tt i và ```node app.js``` li ln na
#### Shell to run
* yarn: yarn dev
* npm: npm start
## C. Learning nodeJS from beginning ...
### Set up
* Create a **package**.json, using **npm init**
* Set port number, using **http.createServer( ... ).listen()**
* Reference at: [Node.js and Express.js - FreeCodeCamp](https://www.youtube.com/watch?v=Oe421EPjeBE)
---
* Install nodejs package to global computer: **sudo npm install -g **
近期下载者:
相关文件:
收藏者: