# 家庭作业程序说明

### 安装nodejs
- 安装方法参见 [https://nodejs.org/en/](https://nodejs.org/en/)

### 文件准备 （若解压后未做修改则已满足）
- inputs.txt的文本内容和题目的输入要求一致
- 以下条件满足其一：
    - inputs.txt文件和程序文件在同一目录下
    - 在程序文件中修改正确的测试文件路径，第2行的`
const filePath = "inputs.txt"`指定了文件路径

### 运行程序 
1. 在程序文件所在的路径中执行如下命令： 
```
    $ node thoughtWorks.js
```  
  
2. 运行的结果应是：  
>  
```
Reminder
==================

* Time-related maintenance coming soon...
Audi: 1 (CAR0006)
Porsche: 1 (CAR0002)

* Distance-related maintenance coming soon...
BYD: 1 (CAR0005)
Ford: 1 (CAR0007)
Porsche: 1 (CAR0001)

* Write-off coming soon...
BYD: 1 (CAR0004)
Ford: 1 (CAR0009)
```
3. 进行以下操作之一：
   - 修改inputs.txt的文本内容为inputs2.txt的内容  
   - 在程序文件中修改`filePath`的值，使其指向inputs2.txt

4. 再次运行步骤1中的命令  

5. 程序的运行结果应是： 
>
```
Reminder
==================

* Time-related maintenance coming soon...
Jeep: 2 (CAR0006, CAR0007)

* Distance-related maintenance coming soon...
Peugeot: 1 (CAR0005)

* Write-off coming soon...
BMW: 1 (CAR0002)
Honda: 1 (CAR0004)
```