In addition, instead of using short names for tags and attributes like s and n, you can change them to size and name, respectively (see Listing 7).
此外,如果标签和属性不愿意使用短名字如s和n,可以分别将其修改为size和name(如图7所示)。
Listing 2's implementation runs in o (n) time. I won't prove this, but the running time of Listing 1's naive, recursive implementation is exponential in n.
清单2中的实现所需的时间比清单1短许多,清单2的运行时间为O (n),而清单1中的递归实现的运行时间是n的指数。
Using the +n or -n parameter, where n is a number, you can rotate the stack left or right, as shown in Listing 5.
使用 +n 或 -n 参数,其中 n 是一个数字,您可以向左或向右移动堆栈,如 清单 5 所示。
应用推荐