# CompilePriciple **Repository Path**: lincyaw/CompilePriciple ## Basic Information - **Project Name**: CompilePriciple - **Description**: No description available - **Primary Language**: C++ - **License**: Not specified - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2021-08-07 - **Last Updated**: 2021-08-07 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # CompilePriciple ## Lab2 LR(1)词法分析 上次上课的时候已经是11月12号了,到现在过去了将近10天, 现在看一下上次写了啥。 上次采用的是自顶向下的设计方法,先假设已经有了`LR(1)` 分析表。那么我就写了下面的一些东西: 1. LR(1)的分析过程,函数名为`Grammar_Analyzer::LR1(string Input)` 2. 初始化动作表`initActionMap()` 3. 初始化转移表`initGotoMap()` ### 第二天 再次思考了一下自己到底要怎么做。 ```c void bubble_sort(int a[], int n); int number[10000000]; int a = 0x123FF; int b = 1234.123; int c = 0123.123; void bubble_sort(int a[], int n) { int i,j,temp; for (j=0;ja[i+1]) { temp=a[i]; a[i]=a[i+1]; a[i+1]=temp; } } } } int main() { int i,n; scanf("%d",&n); for(int j=0;j