UVA10007 Count the Trees

Description

[problemUrl]: https://uva.onlinejudge.org/index.php?option=com_onlinejudge&Itemid=8&category=12&page=show_problem&problem=948 [PDF](https://uva.onlinejudge.org/external/100/p10007.pdf) ![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10007/ba4d4a8cd7c7c5a0fde6a9c130bec06690adf9a4.png)

Input Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10007/43815e1f94a960169fae23afc514bbf4049b2257.png)

Output Format

![](https://cdn.luogu.com.cn/upload/vjudge_pic/UVA10007/9bed85ae530b96ad529443b19668872f0c4db749.png)