2018年11月的全部文章
@kidultff

WordPress调试-输出数据库查询语句和每条语句查询耗时

直接上代码:首先在wp-config.php中底部添加代码,保存查询内容:define('SAVEQUERIES', true);接着找到你主题文件目录里面的页脚文件,一般是footer.php,找到合适位置,添加:echo "<!--"; print_r($wpdb->q ...
  • 0
  • 0
@kidultff

PAT-A 真题 – 1123 Is It a Complete AVL Tree

An AVL tree is a self-balancing binary search tree. In an AVL tree, the heights of the two child subtrees of any node differ by at most one; if at any time they differ by more than one, rebalancing is done to restore this propert ...
  • 0
  • 4
@kidultff

PAT-A 真题 – 1122 Hamiltonian Cycle

The "Hamilton cycle problem" is to find a simple cycle that contains every vertex in a graph. Such a cycle is called a "Hamiltonian cycle".In this problem, you are supposed to tell if a given cycle is a Hamilt ...
  • 0
  • 0
@kidultff

PAT-A 真题 – 1121 Damn Single

"Damn Single (单身狗)" is the Chinese nickname for someone who is being single. You are supposed to find those who are alone in a big party, so they can be taken care of.Input Specification:Each input file contains one ...
  • 0
  • 0
@kidultff

PAT-A 真题 – 1120 Friend Numbers

Two integers are called "friend numbers" if they share the same sum of their digits, and the sum is their "friend ID". For example, 123 and 51 are friend numbers since 1+2+3 = 5+1 = 6, and 6 is their friend ID ...
  • 0
  • 0