Description: 在二叉搜索树上删除一个有两个子女的结点时,可以采用以下三种方法:
(1) 用左子树TL上具有最大关键码的结点X顶替,再递归地删除X。
(2) 交替地用左子树TL上具有最大关键码的结点和右子树TR上具有最小关键码的结点顶替,再递归地删除适当的结点。
(3) 用左子树TL上具有最大关键码的结点或者用右子树TR上具有最小关键码的结点顶替,再递归地删除适当的结点。可随机选择其中一个方案。
-two forks in search of a tree to delete two children nodes, can be used in three ways : (1) to use the left subtree TL on key codes with the greatest of nodes replace X, then X - recursive deleted. (2) to use the turn of the left subtree TL on key codes with the greatest of nodes and right subtrees TR is the smallest key codes node replacement and then recursively to delete the appropriate nodes. (3) The left subtree TL on key codes with the greatest of nodes or use the right subtrees TR is the smallest on the key code top node for further recursion to delete the appropriate nodes. Which can be a random selection program. Platform: |
Size: 1097 |
Author:dfssd |
Hits:
Description: 在二叉搜索树上删除一个有两个子女的结点时,可以采用以下三种方法:
(1) 用左子树TL上具有最大关键码的结点X顶替,再递归地删除X。
(2) 交替地用左子树TL上具有最大关键码的结点和右子树TR上具有最小关键码的结点顶替,再递归地删除适当的结点。
(3) 用左子树TL上具有最大关键码的结点或者用右子树TR上具有最小关键码的结点顶替,再递归地删除适当的结点。可随机选择其中一个方案。
-two forks in search of a tree to delete two children nodes, can be used in three ways : (1) to use the left subtree TL on key codes with the greatest of nodes replace X, then X- recursive deleted. (2) to use the turn of the left subtree TL on key codes with the greatest of nodes and right subtrees TR is the smallest key codes node replacement and then recursively to delete the appropriate nodes. (3) The left subtree TL on key codes with the greatest of nodes or use the right subtrees TR is the smallest on the key code top node for further recursion to delete the appropriate nodes. Which can be a random selection program. Platform: |
Size: 1024 |
Author:dfssd |
Hits:
Description: LL(1)分析 写的语法分析程序,但是不能实现消除左递归,提取公因子-LL (1) analysis of written grammar analysis program, but can not eliminate the left recursion, extracting common factor Platform: |
Size: 194560 |
Author:季 |
Hits:
Description: 用于消除左递归的一个用C++语言实现的小程序。里面包含有详细的报告和源代码。-Used to eliminate the left recursion in a C++ language implementation with a small program. Which contains detailed reports and source code. Platform: |
Size: 726016 |
Author:曾冬梅 |
Hits:
Description: 利用C++语言编制一个LL(1)语法分析器,利用LL(1)控制程序根据显示栈栈顶内容、向前看符号以及LL(1)分析表,对输入符号串自上而下的分析过程。可通过消除左递归、提取左因子把非LL(1)文法改造成LL(1)文法。-Compiled using a C++ language LL (1) parser using LL (1) control program according to display the contents of the stack the stack, forward-looking symbols and LL (1) of the table, the input symbol string of top-down analysis . Through the elimination of left recursion, left-factor of the extraction of non-LL (1) grammar transformation into a LL (1) grammar. Platform: |
Size: 227328 |
Author:杨玥 |
Hits:
Description: 该程序使用的自上而下的LL(1)分析法,,该文法不允许左递归,首先要消除左递归。(The program uses the top-down LL (1) analysis method, which does not allow left recursion, and the left recursion is first eliminated.) Platform: |
Size: 2194432 |
Author:寻常j |
Hits: