2018年2月的全部文章
@kidultff

PAT-A 真题- 1053. Path of Equal Weight

原题干:Given a non-empty tree with root R, and with weight Wi assigned to each tree node Ti. The weight of a path from R to L is defined to be the sum of the weights of all the nodes along the path from R to any l ...
  • 0
  • 1
@kidultff

Linux查找含有某些字符串的所有文件

批量查找文件内容:find . -name "*.log" | xargs grep "fatal"这里*.log指的是要找的文件的后缀名,fatal是要找的内容。
  • 0
  • 0
@kidultff

CentOS升级/安装PHP7.1

首先卸载旧版本PHP:yum remove php*接着安装epel:yum -y install epel-release更新软件源(centos自带的软件源没有PHP7):根据系统版本安装!!//Centos 5.X:     rpm -Uvh http ...
  • 0
  • 0
@kidultff

C语言-树的遍历

0x00、树的静态写法    之前刷PAT的过程中已经接触过树的静态写法了,不过之前接触过的都是二叉树,这里是树。使用数组当做内存,下标当做地址,即可存放静态树。比如这样:struct node{     Elemen ...
  • 0
  • 0
@kidultff

PAT-A 真题- 1102. Invert a Binary Tree

原题干:The following is from Max Howell @twitter:Google: 90% of our engineers use the software you wrote (Homebrew), but you can't invert a binary tree on a whiteboard so fuck off.Now it's your turn to prove that YOU CAN invert ...
  • 0
  • 0