#include 
#include 
#include 
#include 
#include 
#define de(x) cout<<#x<<"="< state_stack;
stack sign_stack;
char G[300][300];     //存文法
int length[300];    //文法的长度
int number=0;    //文法的个数
bool isV[300];      //buffer of input 判断文法中是否出现这个字符
char Vn[300];        //非终结符
int size_vn=0;      
char Vt[300];       //终结符
int size_vt=0;
bool first[300][300];    //first集
char buffer[300];           
int size=0;
struct T        //转换表  项目集转换
{
  int begin;
  int next;
  char ch;
};
struct project      //项目集
{
  int num;
  int now; //小数点位置
                                    
                                    
                                        
                                            1